-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Silvija Tovernic
committed
Sep 21, 2024
1 parent
b548d31
commit 9ab37c2
Showing
1 changed file
with
5 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,6 +16,10 @@ jobs: | |
# Tell GitHub which VM host to use (air-gapped or development) -> TODO: remove when devel env is no longer needed | ||
VM_ENV: ${{ vars.VM_ENV }} | ||
|
||
SSH_KEY: ${{ secrets.SSH_KEY }} | ||
JUMPHOST_IP: ${{ secrets.JUMPHOST_IP }} | ||
RUNNER_HOST_IP: ${{ secrets.RUNNER_HOST_IP }} | ||
|
||
REGISTRY: ${{ secrets.REGISTRY }} | ||
ACR_USERNAME: ${{ secrets.ACR_USERNAME }} | ||
ACR_PASSWORD: ${{ secrets.ACR_PASSWORD }} | ||
|
@@ -55,18 +59,13 @@ jobs: | |
# Air-gapped environment - VM host without internet access | ||
- name: Template Ansible SSH key file for air-gapped environment | ||
uses: cuchi/[email protected] | ||
env: | ||
SSH_KEY: ${{ secrets.SSH_KEY }} | ||
if: env.VM_ENV == 'air-gapped' # -> TODO: remove condition when devel env is no longer needed | ||
with: | ||
template: ansible/templates/ansible_ssh_key.j2 | ||
output_file: ansible/ansible_ssh_key | ||
|
||
- name: Template Ansible inventory for air-gapped environment | ||
uses: cuchi/[email protected] | ||
env: | ||
JUMPHOST_IP: ${{ secrets.JUMPHOST_IP }} | ||
RUNNER_HOST_IP: ${{ secrets.RUNNER_HOST_IP }} | ||
if: env.VM_ENV == 'air-gapped' # -> TODO: remove condition when devel env is no longer needed | ||
with: | ||
template: ansible/templates/inventory.ini.j2 | ||
|
@@ -88,6 +87,7 @@ jobs: | |
- name: Configure VM with Ansible | ||
run: | | ||
cd ansible | ||
eval "$(ssh-agent -s)" | ||
ssh-add ansible_ssh_key | ||
ansible-playbook configure-image-factory-vm.yml | ||
|