Compare commits

...

7 Commits

Author SHA1 Message Date
b7ad335c02 Add schedule :)
All checks were successful
Ansible Deploy / deploy (push) Successful in 1m3s
2023-11-24 08:31:26 +02:00
bf45b66782 Inventory is no more
All checks were successful
Ansible Deploy / deploy (push) Successful in 1m4s
2023-11-21 23:03:31 +02:00
98e05fe930 Update .gitea/workflows/hatarashi-hako.yaml
All checks were successful
Ansible Deploy / deploy (push) Successful in 1m4s
2023-11-21 22:48:56 +02:00
a1462c543b Update .gitea/workflows/hatarashi-hako.yaml
All checks were successful
Ansible Deploy / deploy (push) Successful in 54s
2023-11-21 22:43:15 +02:00
5e4ecc9447 Update .gitea/workflows/hatarashi-hako.yaml
All checks were successful
Ansible Deploy / deploy (push) Successful in 58s
2023-11-21 22:41:18 +02:00
7fb05e9b58 Update .gitea/workflows/hatarashi-hako.yaml
Some checks failed
Ansible Deploy / deploy (push) Has been cancelled
2023-11-21 22:40:29 +02:00
e337369951 Use inventory from split Ansible repository
Some checks failed
Ansible Deploy / deploy (push) Failing after 1m0s
2023-11-21 22:34:29 +02:00
2 changed files with 39 additions and 36 deletions

View File

@@ -1,31 +1,39 @@
name: Ansible Deploy
on:
push:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Set up Python
run: |
apt -y update
apt -y install python3 python3-pip skopeo
- name: Install Ansible
run: |
python3 -m pip install --upgrade pip
pip install ansible
- name: Set up SSH
uses: webfactory/ssh-agent@v0.5.0
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Run Ansible Playbook
run: |
ansible-playbook -i inventory.yaml -e 'ANSIBLE_SUDO_PASS="${{ secrets.SUDO_PASS }}" SKOPEO_PASS="${{ secrets.SKOPEO_PASS }}"' hatarashi-hako.yaml -vv
name: Ansible Deploy
on:
push:
schedule:
- cron: '00 23 * * *'
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Set up Python
run: |
apt -y update
apt -y install python3 python3-pip skopeo
- name: Install Ansible
run: |
python3 -m pip install --upgrade pip
pip install ansible
- name: Set up SSH
uses: webfactory/ssh-agent@v0.5.0
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Checkout Ansible inventory
run: |
INVENTORY_URL="https://shmick:${{ secrets.ANSIBLE_TOKEN }}@git.pukeko.xyz/shmick/ansible/raw/branch/main/inventory.yaml"
curl -o inventory.yaml $INVENTORY_URL
cat inventory.yaml
- name: Run Ansible Playbook
run: |
ansible-playbook -i inventory.yaml -e 'ANSIBLE_SUDO_PASS="${{ secrets.SUDO_PASS }}" SKOPEO_PASS="${{ secrets.SKOPEO_PASS }}"' hatarashi-hako.yaml -vv

View File

@@ -1,5 +0,0 @@
all:
hosts:
takahe:
ansible_host: 192.168.0.66
ansible_user: shmick