feat(secrets): integrate Infisical Universal Auth into Gitea Actions workflows
- Configure Infisical CLI authentication via INFISICAL_CLIENT_ID and INFISICAL_CLIENT_SECRET - Fetch runner SSH keys and state tokens dynamically from /ci-cd - Fetch Proxmox target endpoints and tokens dynamically from /proxmox/<TARGET> - Remove plaintext secrets from Ansible core_secrets defaults - Clean up obsolete files and add --remove-orphans to docker compose invocations
This commit is contained in:
1 parent
efc23dfac2
commit
d2888c1149
14 files changed
+124
-70
No files matched your search
@@ -4,4 +4,3 @@ traefik_dir: "/opt/traefik"
|
||||
traefik_dynamic_dir: "/opt/traefik/dynamic"
|
||||
traefik_log_dir: "/var/log/traefik"
|
||||
traefik_acme_email: "vvkarpenok@gmail.com"
|
||||
traefik_dashboard_auth: 'karpenok:$apr1$dYhfMHp0$/xqbASu5jj55Ev058YImp.'
|
||||
@@ -1,15 +0,0 @@
|
||||
http:
|
||||
routers:
|
||||
test:
|
||||
rule: "Host(`test.gunihome.ru`)"
|
||||
entryPoints:
|
||||
- websecure
|
||||
service: test
|
||||
tls:
|
||||
certResolver: letsencrypt
|
||||
|
||||
services:
|
||||
test:
|
||||
loadBalancer:
|
||||
servers:
|
||||
- url: "http://192.168.1.228:8317"
|
||||
@@ -1,4 +1,4 @@
|
||||
---
|
||||
- name: Перезапустить Traefik
|
||||
ansible.builtin.command: docker compose -f {{ traefik_dir }}/compose.yaml restart
|
||||
ansible.builtin.command: docker compose -f {{ traefik_dir }}/compose.yaml up -d --force-recreate --remove-orphans
|
||||
changed_when: true
|
||||
@@ -84,6 +84,6 @@
|
||||
when: item.path | basename not in repo_files
|
||||
|
||||
- name: Запустить Traefik через Docker Compose
|
||||
ansible.builtin.command: docker compose -f {{ traefik_dir }}/compose.yaml up -d
|
||||
ansible.builtin.command: docker compose -f {{ traefik_dir }}/compose.yaml up -d --remove-orphans
|
||||
register: compose_up
|
||||
changed_when: "'Started' in compose_up.stdout or 'Running' in compose_up.stdout or 'Created' in compose_up.stdout"
|
||||
changed_when: "'Started' in compose_up.stderr or 'Created' in compose_up.stderr or 'Recreated' in compose_up.stderr or 'Pulled' in compose_up.stderr"
|
||||
@@ -10,8 +10,8 @@ vaultwarden_domain: "https://pass.gunihome.ru"
|
||||
infisical_site_url: "https://infisical.gunihome.ru"
|
||||
|
||||
infisical_postgres_user: "infisical"
|
||||
infisical_postgres_password: "Vrl2cqlvXNGtf5h8WOT5eqPsgLmHJJCt"
|
||||
infisical_postgres_password: "{{ lookup('env', 'INFISICAL_POSTGRES_PASSWORD') }}"
|
||||
infisical_postgres_db: "infisical"
|
||||
infisical_encryption_key: "20e2553f18b49f077441eaf7699c1d18"
|
||||
infisical_auth_secret: "j+n6OqMIZpsnhS1QoHeHa4orTh6CBEDln7SzqDa826U="
|
||||
infisical_encryption_key: "{{ lookup('env', 'INFISICAL_ENCRYPTION_KEY') }}"
|
||||
infisical_auth_secret: "{{ lookup('env', 'INFISICAL_AUTH_SECRET') }}"
|
||||
|
||||
@@ -33,8 +33,6 @@
|
||||
- "{{ secrets_dir }}"
|
||||
- "{{ vaultwarden_data_dir }}"
|
||||
- "{{ infisical_data_dir }}"
|
||||
- "{{ infisical_data_dir }}/db"
|
||||
- "{{ infisical_data_dir }}/redis"
|
||||
|
||||
- name: Установить compose.yaml для core-secrets
|
||||
ansible.builtin.template:
|
||||
@@ -45,6 +43,6 @@
|
||||
mode: "0640"
|
||||
|
||||
- name: Запустить сервисы core-secrets через Docker Compose
|
||||
ansible.builtin.command: docker compose -f {{ secrets_dir }}/compose.yaml up -d
|
||||
ansible.builtin.command: docker compose -f {{ secrets_dir }}/compose.yaml up -d --remove-orphans
|
||||
register: compose_up
|
||||
changed_when: "'Started' in compose_up.stdout or 'Running' in compose_up.stdout or 'Created' in compose_up.stdout or 'Pulled' in compose_up.stdout"
|
||||
changed_when: "'Started' in compose_up.stderr or 'Created' in compose_up.stderr or 'Recreated' in compose_up.stderr or 'Pulled' in compose_up.stderr"
|
||||
@@ -5,7 +5,7 @@ services:
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- DOMAIN={{ vaultwarden_domain }}
|
||||
- SIGNUPS_ALLOWED=true
|
||||
- SIGNUPS_ALLOWED=false
|
||||
- INVITATIONS_ALLOWED=true
|
||||
- SHOW_PASSWORD_HINT=false
|
||||
- WEBSOCKET_ENABLED=true
|
||||
|
||||
Reference in new issue
Block a user