diff options
Diffstat (limited to 'deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml')
-rwxr-xr-x | deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml new file mode 100755 index 00000000..4e914749 --- /dev/null +++ b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml @@ -0,0 +1,22 @@ +--- +#- hosts: all +# sudo: yes +# tasks: +- name: "configure interface" +# sudo: True + lineinfile: + dest: "/etc/network/interfaces" + line: "{{ item }}" + with_items: + - "auto {{ contrail_device }}" + - "iface {{ contrail_device }} inet static" + - "\taddress {{ contrail_address }}" + - "\tnetmask {{ contrail_netmask }}" + +- name: "set interface address" +# sudo: True + shell: "ifconfig {{ contrail_device }} {{ contrail_address }} netmask {{ contrail_netmask }}" + +- name: "up interface" +# sudo: True + shell: "ifconfig {{ contrail_device }} up" |