From d2ce20787dc051da17b2e5a9e3750e125eb3f872 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Mattm=C3=BCller?= Date: Mon, 21 Aug 2023 16:34:44 +0200 Subject: [PATCH] playbooks: updated hosts with target variable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit the playbooks shall only run on the hosts provided by the variable target. NOTE: the default target is set within the job templates Signed-off-by: Marc Mattmüller --- playbooks/getting_started/basic-pkg-installation.yml | 2 +- playbooks/getting_started/build-jenkins-docker-image.yml | 2 +- playbooks/getting_started/clone-repository.yml | 2 +- playbooks/getting_started/configure-docker-net.yml | 2 +- playbooks/getting_started/create-ssh-key.yml | 2 +- playbooks/getting_started/os-rls.yml | 2 +- playbooks/getting_started/setup-nwl-jenkins-seedjob-git-url.yml | 2 +- playbooks/getting_started/setup-nwl-jenkins.yaml | 2 +- playbooks/getting_started/start-stop-nwl-jenkins.yml | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/playbooks/getting_started/basic-pkg-installation.yml b/playbooks/getting_started/basic-pkg-installation.yml index 4bd2112..e6aff46 100644 --- a/playbooks/getting_started/basic-pkg-installation.yml +++ b/playbooks/getting_started/basic-pkg-installation.yml @@ -1,5 +1,5 @@ - name: Setup Basic Debian Host Machine - hosts: linux + hosts: "{{ target }}" become: yes tasks: - name: Update Apt Cache and Upgrade all Packages diff --git a/playbooks/getting_started/build-jenkins-docker-image.yml b/playbooks/getting_started/build-jenkins-docker-image.yml index 221490b..7ab01f3 100644 --- a/playbooks/getting_started/build-jenkins-docker-image.yml +++ b/playbooks/getting_started/build-jenkins-docker-image.yml @@ -1,5 +1,5 @@ - name: Build Jenkins Docker Image - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: root_path: "~/nwl-ci" diff --git a/playbooks/getting_started/clone-repository.yml b/playbooks/getting_started/clone-repository.yml index 214ce6a..b185f9e 100644 --- a/playbooks/getting_started/clone-repository.yml +++ b/playbooks/getting_started/clone-repository.yml @@ -1,5 +1,5 @@ - name: Clone a Git Repository - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: git_repo_path: "~/nwl-ci" diff --git a/playbooks/getting_started/configure-docker-net.yml b/playbooks/getting_started/configure-docker-net.yml index 42a803d..790081b 100644 --- a/playbooks/getting_started/configure-docker-net.yml +++ b/playbooks/getting_started/configure-docker-net.yml @@ -1,5 +1,5 @@ - name: Configure Docker Network Adapter - hosts: linux + hosts: "{{ target }}" gather_facts: false become: yes tasks: diff --git a/playbooks/getting_started/create-ssh-key.yml b/playbooks/getting_started/create-ssh-key.yml index 4c71ee5..9ab21a4 100644 --- a/playbooks/getting_started/create-ssh-key.yml +++ b/playbooks/getting_started/create-ssh-key.yml @@ -1,5 +1,5 @@ - name: Create SSH Keypair - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: ssh_passphrase: !vault | diff --git a/playbooks/getting_started/os-rls.yml b/playbooks/getting_started/os-rls.yml index cbcf326..d250f8a 100644 --- a/playbooks/getting_started/os-rls.yml +++ b/playbooks/getting_started/os-rls.yml @@ -1,5 +1,5 @@ - name: The First Playbook - hosts: linux + hosts: "{{ target }}" tags: - rls gather_facts: False diff --git a/playbooks/getting_started/setup-nwl-jenkins-seedjob-git-url.yml b/playbooks/getting_started/setup-nwl-jenkins-seedjob-git-url.yml index 8b3eb45..df53f92 100644 --- a/playbooks/getting_started/setup-nwl-jenkins-seedjob-git-url.yml +++ b/playbooks/getting_started/setup-nwl-jenkins-seedjob-git-url.yml @@ -1,5 +1,5 @@ - name: Setup NWL Git URL For Jenkins Seed Job - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: root_path: "~/nwl-ci" diff --git a/playbooks/getting_started/setup-nwl-jenkins.yaml b/playbooks/getting_started/setup-nwl-jenkins.yaml index 9b9c4e3..8c4a7c0 100644 --- a/playbooks/getting_started/setup-nwl-jenkins.yaml +++ b/playbooks/getting_started/setup-nwl-jenkins.yaml @@ -1,5 +1,5 @@ - name: Setup Jenkins Instance - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: root_path: "~/nwl-ci" diff --git a/playbooks/getting_started/start-stop-nwl-jenkins.yml b/playbooks/getting_started/start-stop-nwl-jenkins.yml index aad8b0a..7bb1820 100644 --- a/playbooks/getting_started/start-stop-nwl-jenkins.yml +++ b/playbooks/getting_started/start-stop-nwl-jenkins.yml @@ -1,5 +1,5 @@ - name: Start or Stop NWL Jenkins Instance - hosts: linux + hosts: "{{ target }}" gather_facts: false vars: root_path: "~/nwl-ci"