Refactor ansible-apply.yaml to improve SSH key handling
This commit is contained in:
@@ -10,7 +10,7 @@ on:
|
||||
- closed
|
||||
|
||||
jobs:
|
||||
plan:
|
||||
apply-playbooks:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
@@ -31,9 +31,9 @@ jobs:
|
||||
VAULT_MASTER_PASSWORD: ${{ secrets.VAULT_MASTER_PASSWORD }}
|
||||
run: |
|
||||
sectool ssh unlock ansible
|
||||
cp ssh-keys/ansible ~/.ssh/id_rsa
|
||||
mkdir -p ~/.ssh
|
||||
chmod 700 ~/.ssh
|
||||
cp ssh-keys/ansible/id_rsa ~/.ssh/id_rsa
|
||||
chmod 600 ~/.ssh/id_rsa
|
||||
|
||||
- name: Apply Ansible Playbook
|
||||
|
||||
@@ -10,7 +10,7 @@ on:
|
||||
- reopened
|
||||
|
||||
jobs:
|
||||
plan:
|
||||
validate-playbooks:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
@@ -22,8 +22,6 @@ jobs:
|
||||
|
||||
- name: Setup Sectool
|
||||
uses: a13labs/setup-sectool@v1
|
||||
with:
|
||||
version: 0.0.3
|
||||
|
||||
- name: Terraform Init
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user