From cb3895c81c6931482e688a820013f6926644221d Mon Sep 17 00:00:00 2001 From: Georg Kunz Date: Mon, 24 Aug 2020 23:09:51 +0200 Subject: Implementing jump VM create via ansible This patch reimplements the creation of the jump VM as ansible playbook. The advantage of this approach is a more deterministic behavior and the ability to render configuration files using templates based on the pdf and idf. Moreover, this patch allows to overwrite the VENDOR variable. This is necessary to allow deployment in different labs via CI. The BMRA configuration has not yet been transformed to ansible template and needs to follow in subsequent patches. Signed-off-by: Georg Kunz Signed-off-by: Victor Morales Change-Id: I2cde41dcecec7480bddf71ed864f06244a89f1f3 Reviewed-on: https://gerrit.opnfv.org/gerrit/c/kuberef/+/70882 Tested-by: jenkins-ci Reviewed-by: Victor Morales --- playbooks/roles/bootstrap/tasks/main.yaml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 playbooks/roles/bootstrap/tasks/main.yaml (limited to 'playbooks/roles/bootstrap/tasks') diff --git a/playbooks/roles/bootstrap/tasks/main.yaml b/playbooks/roles/bootstrap/tasks/main.yaml new file mode 100644 index 0000000..ff20552 --- /dev/null +++ b/playbooks/roles/bootstrap/tasks/main.yaml @@ -0,0 +1,20 @@ +--- +############################################################################## +# Copyright (c) Ericsson AB 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 +############################################################################## + +# collected PDF and IDF are copied into group_vars +# folder in order to ensure we have single PDF and IDF +- name: Copy collected PDF and IDF to group_vars + copy: + src: "{{ item.src }}" + dest: "{{ item.dest }}" + force: true + mode: 0644 + with_items: + - {src: "{{ kuberef_root }}/hw_config/{{ lookup('env', 'VENDOR') }}/pdf.yaml", dest: "{{ inventory_path }}/group_vars/all/pdf.yaml"} + - {src: "{{ kuberef_root }}/hw_config/{{ lookup('env', 'VENDOR') }}/idf.yaml", dest: "{{ inventory_path }}/group_vars/all/idf.yaml"} -- cgit 1.2.3-korg