Skip to content

Commit dd3bd12

Browse files
author
Mafyuh
committedJan 13, 2025
misc updates
1 parent 3d94aee commit dd3bd12

File tree

5 files changed

+17
-12
lines changed

5 files changed

+17
-12
lines changed
 

‎.forgejo/workflows/CD.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ jobs:
104104
base_url: https://vault.bitwarden.com
105105
secrets: |
106106
267abc49-f755-4c88-a2a8-b23d00503e31 > arrs_host
107+
d9924181-b061-44e0-b7b9-b264004791eb > ag_main_host
107108
e74d1f67-c909-4a2e-b6fc-b23e001dfa4a > ai_host
108109
6f9cef86-eb39-4e05-8c5b-b23e001e6170 > arm_host
109110
52512c15-b474-42c3-9835-b23e001edf35 > auth_host
@@ -121,6 +122,7 @@ jobs:
121122
run: |
122123
cat <<EOF > ansible/hosts.ini
123124
[iac]
125+
dns.lan ansible_host=${{ steps.bitwarden-secrets.outputs.ag_main_host }} ansible_user=mafyuh
124126
arrs.lan ansible_host=${{ steps.bitwarden-secrets.outputs.arrs_host }} ansible_user=mafyuh
125127
ai.lan ansible_host=${{ steps.bitwarden-secrets.outputs.ai_host }} ansible_user=mafyuh ansible_port=2424
126128
arm.lan ansible_host=${{ steps.bitwarden-secrets.outputs.arm_host }} ansible_user=ubuntu ansible_port=2424

‎.forgejo/workflows/ansible-playbooks.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ jobs:
3838
base_url: https://vault.bitwarden.com
3939
secrets: |
4040
267abc49-f755-4c88-a2a8-b23d00503e31 > arrs_host
41+
d9924181-b061-44e0-b7b9-b264004791eb > ag_main_host
4142
e74d1f67-c909-4a2e-b6fc-b23e001dfa4a > ai_host
4243
6f9cef86-eb39-4e05-8c5b-b23e001e6170 > arm_host
4344
52512c15-b474-42c3-9835-b23e001edf35 > auth_host
@@ -59,6 +60,7 @@ jobs:
5960
ai.lan ansible_host=${{ steps.bitwarden-secrets.outputs.ai_host }} ansible_user=mafyuh ansible_port=2424
6061
arm.lan ansible_host=${{ steps.bitwarden-secrets.outputs.arm_host }} ansible_user=ubuntu ansible_port=2424
6162
auth.lan ansible_host=${{ steps.bitwarden-secrets.outputs.auth_host }} ansible_user=mafyuh
63+
dns.lan ansible_host=${{ steps.bitwarden-secrets.outputs.ag_main_host }} ansible_user=mafyuh
6264
jf.lan ansible_host=${{ steps.bitwarden-secrets.outputs.jf_host }} ansible_user=mafyuh
6365
kasm.lan ansible_host=${{ steps.bitwarden-secrets.outputs.kasm_host }} ansible_user=mafyuh
6466
netboot.lan ansible_host=${{ steps.bitwarden-secrets.outputs.netboot_host }} ansible_user=mafyuh

‎README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
[![Yamllint](https://git.mafyuh.dev/mafyuh/iac/badges/workflows/yamllint.yml/badge.svg)](https://git.mafyuh.dev/mafyuh/iac/actions)
2-
[![Yamllint](https://git.mafyuh.dev/mafyuh/iac/badges/workflows/CD.yml/badge.svg)](https://git.mafyuh.dev/mafyuh/iac/actions)
2+
[![CD](https://git.mafyuh.dev/mafyuh/iac/badges/workflows/CD.yml/badge.svg)](https://git.mafyuh.dev/mafyuh/iac/actions)
3+
[![Ansible](https://git.mafyuh.dev/mafyuh/iac/badges/workflows/ansible-playbooks.yml/badge.svg)](https://git.mafyuh.dev/mafyuh/iac/actions)
34
[![Tofu](https://git.mafyuh.dev/mafyuh/iac/badges/workflows/tofu.yml/badge.svg)](https://git.mafyuh.dev/mafyuh/iac/actions)
45
[![Renovate](https://git.mafyuh.dev/renovatebot/renovate/badges/workflows/renovate.yml/badge.svg)](https://git.mafyuh.dev/renovatebot/renovate/actions)
56
[![Pulls](https://git.mafyuh.dev/mafyuh/iac/badges/pulls.svg)](https://git.mafyuh.dev/mafyuh/iac/pulls)

‎ansible/playbooks/deploy-docker.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,18 @@
22
hosts: "{{ target_host }}"
33
vars:
44
repo_path: "/home/{{ ansible_user }}/iac/docker/{{ folder }}"
5-
secrets_mapping_file: "/home/{{ ansible_user }}/iac/secret-mappings.yml"
5+
secrets_mapping_file: "/home/{{ ansible_user }}/iac/docker/secret-mappings.yml"
66
tasks:
7+
- name: Ensure the repository is up-to-date
8+
ansible.builtin.shell: git pull
9+
args:
10+
chdir: "{{ repo_path }}"
11+
register: git_pull_output
12+
13+
- name: Display git pull output
14+
ansible.builtin.debug:
15+
var: git_pull_output.stdout_lines
16+
717
- name: Read secret mapping
818
ansible.builtin.slurp:
919
src: "{{ secrets_mapping_file }}"
@@ -25,16 +35,6 @@
2535
{{ key }}={{ lookup('bitwarden.secrets.lookup', secret_id, access_token=bw_access_token) }}
2636
{% endfor %}
2737
28-
- name: Ensure the repository is up-to-date
29-
ansible.builtin.shell: git pull
30-
args:
31-
chdir: "{{ repo_path }}"
32-
register: git_pull_output
33-
34-
- name: Display git pull output
35-
ansible.builtin.debug:
36-
var: git_pull_output.stdout_lines
37-
3838
- name: Restart services using Docker Compose
3939
community.docker.docker_compose_v2:
4040
project_src: "{{ repo_path }}"
File renamed without changes.

0 commit comments

Comments
 (0)
Please sign in to comment.