summaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/open-contrail/tasks/install
diff options
context:
space:
mode:
authorliyuenan <liyuenan@huawei.com>2016-12-27 17:44:34 +0800
committerliyuenan <liyuenan@huawei.com>2017-01-05 09:42:35 +0800
commit92f6ca7bb6d7b2f295406aab34094b1dba76ff94 (patch)
treec4e62927a3bf9862f7ba9ce286cbece2c4335ef4 /deploy/adapters/ansible/roles/open-contrail/tasks/install
parent6072a49adb33f2bce3f48b9c7b8be7d96cf8501c (diff)
Yamllint test
JIRA: COMPASS-516 Change-Id: I482ce9bc86f4f963258c5b8823e0b00e83556eef Signed-off-by: liyuenan <liyuenan@huawei.com>
Diffstat (limited to 'deploy/adapters/ansible/roles/open-contrail/tasks/install')
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-collector.yml24
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-common.yml104
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-compute.yml55
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-config.yml51
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-control.yml32
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-database.yml25
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml34
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-kernel.yml60
-rwxr-xr-xdeploy/adapters/ansible/roles/open-contrail/tasks/install/install-webui.yml26
9 files changed, 0 insertions, 411 deletions
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-collector.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-collector.yml
deleted file mode 100755
index d3022893..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-collector.yml
+++ /dev/null
@@ -1,24 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: collector
-# sudo: yes
-# tasks:
-
-- name: "temporary disable supervisor analytics"
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-analytics.override"
-
-- name: "install contrail openstack analytics package"
-# apt:
-# name: "contrail-openstack-analytics"
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: collector_package
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-common.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-common.yml
deleted file mode 100755
index e94621bc..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-common.yml
+++ /dev/null
@@ -1,104 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: all
-# sudo: yes
-# tasks:
-#- name: "copy contrail install package temporary"
-# sudo: True
-# copy:
-# src: "{{ package }}"
-# dest: "/tmp/{{ package }}"
-
-- name: get image http server
- shell: awk -F'=' '/compass_server/ {print $2}' /etc/compass.conf
- register: http_server
-
-- name: download OpenContrail package file
- get_url: url="http://{{ http_server.stdout_lines[0] }}/packages/open-contrail/{{ package }}" dest=/tmp/{{ package }}
-#"
-
-- name: "install contrail install package"
-# sudo: True
- apt:
- deb: "/tmp/{{ package }}"
- force: yes
-
-- name: "delete temporary contrail install package"
-# sudo: True
- file:
- dest: "/tmp/{{ package }}"
- state: "absent"
-
-- name: "make directory for contrail binary files"
-# sudo: True
- file:
- path: "/opt/contrail/bin"
- state: "directory"
-
-- name: "make directory for contrail repository"
-# sudo: True
- file:
- path: "/opt/contrail/contrail_install_repo"
- state: "directory"
-
-- name: "unarchive contrail packages"
-# sudo: True
- unarchive:
- src: "/opt/contrail/contrail_packages/contrail_debs.tgz"
- dest: "/opt/contrail/contrail_install_repo"
- copy: no
-
-- name: "find required packages in advance"
-# sudo: True
- shell: "find /opt/contrail/contrail_install_repo -name binutils_*.deb -or -name make_*.deb -or -name libdpkg-perl_*.deb -or -name dpkg-dev_*.deb -or -name patch_*.deb -type f"
- register: required_packages
- changed_when: no
-
-- name: "install required packages"
-# sudo: True
- apt:
- deb: "{{ item }}"
- force: yes
- with_items: required_packages.stdout_lines
- ignore_errors: True
-
-- name: modify source list
-# sudo: True
- lineinfile:
- dest: "/etc/apt/sources.list"
- line: "deb file:/opt/contrail/contrail_install_repo ./"
- insertbefore: "BOF"
-
-- name: "modify apt configuration"
-# sudo: True
- lineinfile:
- dest: "/etc/apt/apt.conf"
- line: "APT::Get::AllowUnauthenticated \"true\";"
- create: "yes"
-
-- name: "copy apt preferences file"
-# sudo: True
- shell: "cp /opt/contrail/contrail_packages/preferences /etc/apt/preferences"
- args:
- creates: "/etc/apt/preferences"
-
-- name: create contrail packages list
-# sudo: True
- shell: "dpkg-scanpackages . | gzip -9c > Packages.gz"
- args:
- chdir: "/opt/contrail/contrail_install_repo"
- creates: "Packages.gz"
-
-- name: install contrail setup package
- sudo: True
- apt:
- name: "contrail-setup"
- update_cache: yes
- force: yes
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-compute.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-compute.yml
deleted file mode 100755
index 4e4a5ad5..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-compute.yml
+++ /dev/null
@@ -1,55 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: [compute, tsn]
-# sudo: yes
-# tasks:
-- name: "temporary disable supervisor vrouter"
-# sudo: True
- template:
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-vrouter.override"
-
-# - name: "install nova-compute for contrail package"
-# apt:
-# name: "nova-compute"
-# when: install_nova
-
-- name: "install contrail vrouter 3.13.0-40 package"
-# apt:
-# name: "contrail-vrouter-3.13.0-40-generic"
-# when: ansible_kernel == "3.13.0-40-generic"
-# sudo: True
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: vrouter_package
- when: ansible_kernel == kernel_required
-
-- name: "install contrail vrouter dkms package"
-# apt:
-# name: "contrail-vrouter-dkms"
-# when: ansible_kernel != "3.13.0-40-generic"
-# sudo: True
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: dkms_package
- when: ansible_kernel != kernel_required
-
-# - name: "install contrail vrouter common package"
-# apt:
-# name: "contrail-vrouter-common"
-
-# - name: "install contrail nova vif package"
-# apt:
-# name: "contrail-nova-vif"
-
-- name: "install contrail vrouter common & nova vif package"
-# sudo: True
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present"
- with_items: compute_package | union(compute_package_noarch)
-
-
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-config.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-config.yml
deleted file mode 100755
index b66e3e45..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-config.yml
+++ /dev/null
@@ -1,51 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: config
-# sudo: yes
-# tasks:
-- name: "temporary disable supervisor config"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-config.override"
-
-- name: "temporary disable neutron server"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/neutron-server.override"
-
-###############################################
-################ workaround #################
-###############################################
-- name: "backup keepalived conf"
- shell: mv /etc/keepalived/keepalived.conf /home/keepalived.conf
-
-- name: "uninstall keepalived"
- action: "{{ ansible_pkg_mgr }} name=keepalived state=absent"
-
-- name: "install iproute"
- action: "{{ ansible_pkg_mgr }} name=iproute state=present"
-
-- name: "install iproute"
- action: "{{ ansible_pkg_mgr }} name=keepalived state=present"
-
-- name: "restore keepalived conf"
- shell: mv /home/keepalived.conf /etc/keepalived/keepalived.conf
-###############################################
-
-- name: "install contrail openstack config package"
-# sudo: True
-# apt:
-# name: "contrail-openstack-config"
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: config_package
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-control.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-control.yml
deleted file mode 100755
index ab7d4ad3..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-control.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: control
-# sudo: yes
-# tasks:
-- name: "temporary disable supervisor control"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-control.override"
-
-- name: "temporary disable supervisor dns"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-dns.override"
-
-- name: "install contrail openstack control package"
-# sudo: True
-# apt:
-# name: "contrail-openstack-control"
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: control_package
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-database.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-database.yml
deleted file mode 100755
index 5c89ede9..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-database.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: database
-# sudo: yes
-# tasks:
-- name: "temporary disable supervisor database"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-database.override"
-
-- name: "install contrail openstack database package"
-# sudo: True
-# apt:
-# name: "contrail-openstack-database"
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: database_package
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
deleted file mode 100755
index 3f7b43c1..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-interface.yml
+++ /dev/null
@@ -1,34 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: all
-# sudo: yes
-# tasks:
-#- name: get last ip address
-# shell: expr substr `cat /etc/hostname` 5 1
-# register: lastip
-
-#- name: "configure interface"
-## sudo: True
-# lineinfile:
-# dest: "/etc/network/interfaces"
-# line: "{{ item }}"
-# with_items:
-# - "auto {{ contrail_vhost_device }}"
-# - "iface {{ contrail_vhost_device }} inet static"
-# - "\taddress {{ contrail_vhost_address }}"
-# - "\tnetmask {{ contrail_vhost_netmask }}"
-
-- name: "set interface address"
-# sudo: True
- shell: "ifconfig {{ contrail_vhost_device }} {{ contrail_vhost_address }} netmask {{ contrail_vhost_netmask }}"
-
-- name: "up interface"
-# sudo: True
- shell: "ifconfig {{ contrail_vhost_device }} up"
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-kernel.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-kernel.yml
deleted file mode 100755
index be9a8ac9..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-kernel.yml
+++ /dev/null
@@ -1,60 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: all
-# sudo: yes
-# tasks:
-
-- name: "install Ubuntu kernel"
-# sudo: True
-# apt:
-# name: "linux-headers-3.13.0-40"
-# name: "linux-headers-3.13.0-40-generic"
-# name: "linux-image-3.13.0-40-generic"
-# name: "linux-image-extra-3.13.0-40-generic"
-# when: (kernel_install) and (ansible_kernel != "3.13.0-40-generic")
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: kernel_package | union(kernel_package_noarch)
- when: (kernel_install) and (ansible_kernel != kernel_required)
-
-- name: "setup grub"
-# sudo: True
- lineinfile:
- dest: "/etc/default/grub"
- regexp: "GRUB_DEFAULT=.*"
- line: "GRUB_DEFAULT='Advanced options for Ubuntu>Ubuntu, with Linux 3.13.0-40-generic'"
-# when: (kernel_install) and (ansible_kernel != "3.13.0-40-generic")
- when: (kernel_install) and (ansible_kernel != kernel_required)
-
-- name: "reflect grub"
-# sudo: True
- shell: "update-grub2"
-# when: (kernel_install) and (ansible_kernel != "3.13.0-40-generic")
- when: (kernel_install) and (ansible_kernel != kernel_required)
-
-- name: "reboot Server"
-# sudo: True
- shell: "shutdown -r now"
- async: 0
- poll: 0
- ignore_errors: true
- notify: Wait for server to come back
-# when: (kernel_install) and (ansible_kernel != "3.13.0-40-generic")
- when: (kernel_install) and (ansible_kernel != kernel_required)
-
-# handlers:
-- name: "Wait for server to come back"
- local_action:
- module: wait_for
- host={{ inventory_hostname }}
- port=22
- delay=30
- timeout=600
-# when: (kernel_install) and (ansible_kernel != "3.13.0-40-generic")
- when: (kernel_install) and (ansible_kernel != kernel_required)
diff --git a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-webui.yml b/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-webui.yml
deleted file mode 100755
index 6dbe1e74..00000000
--- a/deploy/adapters/ansible/roles/open-contrail/tasks/install/install-webui.yml
+++ /dev/null
@@ -1,26 +0,0 @@
-##############################################################################
-# Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
----
-#- hosts: webui
-# sudo: yes
-# tasks:
-
-- name: "temporary disable supervisor webui"
-# sudo: True
- template:
-# src: "templates/override.j2"
- src: "../../templates/install/override.j2"
- dest: "/etc/init/supervisor-webui.override"
-
-- name: "install contrail openstack webui package"
-# sudo: True
-# apt:
-# name: "contrail-openstack-webui"
- action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes"
- with_items: webui_package