From 42326a0e319a6ee489b42c014e1ef2839ee1a3e2 Mon Sep 17 00:00:00 2001 From: Gleb Koval Date: Tue, 26 Nov 2024 19:53:33 +0000 Subject: [PATCH] fix: use project_id in firefly-iii playbook infisical requests --- infra/finance/0003_firefly-iii_playbook.yaml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/infra/finance/0003_firefly-iii_playbook.yaml b/infra/finance/0003_firefly-iii_playbook.yaml index 01e387b..77de836 100644 --- a/infra/finance/0003_firefly-iii_playbook.yaml +++ b/infra/finance/0003_firefly-iii_playbook.yaml @@ -27,17 +27,20 @@ ansible.builtin.replace: path: "$HOME/{{ app }}/.env" regexp: "APP_KEY_VALUE" - replace: "{{ lookup('infisical.vault.read_secrets', env_slug='prod', path='/finance', secret_name='APP_KEY')['value'] }}" + replace: "{{ lookup('infisical.vault.read_secrets', project_id=infisical_project, env_slug='prod', + path='/finance', secret_name='APP_KEY')['value'] }}" - name: Replace DB secret ansible.builtin.replace: path: "$HOME/{{ app }}/.env" regexp: "DB_PASSWORD_VALUE" - replace: "{{ lookup('infisical.vault.read_secrets', env_slug='prod', path='/finance', secret_name='DB_PASSWORD')['value'] }}" + replace: "{{ lookup('infisical.vault.read_secrets', project_id=infisical_project, env_slug='prod', + path='/finance', secret_name='DB_PASSWORD')['value'] }}" - name: Replace cron token secret ansible.builtin.replace: path: "$HOME/{{ app }}/.env" regexp: "STATIC_CRON_TOKEN_VALUE" - replace: "{{ lookup('infisical.vault.read_secrets', env_slug='prod', path='/finance', secret_name='STATIC_CRON_TOKEN')['value'] }}" + replace: "{{ lookup('infisical.vault.read_secrets', project_id=infisical_project, env_slug='prod', + path='/finance', secret_name='STATIC_CRON_TOKEN')['value'] }}" - name: Replace SMTP Password secret (app) ansible.builtin.replace: path: "$HOME/{{ app }}/.env" @@ -48,12 +51,14 @@ ansible.builtin.replace: path: "$HOME/{{ app }}/.importer.env" regexp: "NORDIGEN_ID_VALUE" - replace: "{{ lookup('infisical.vault.read_secrets', env_slug='prod', path='/finance', secret_name='NORDIGEN_ID')['value'] }}" + replace: "{{ lookup('infisical.vault.read_secrets', project_id=infisical_project, env_slug='prod', + path='/finance', secret_name='NORDIGEN_ID')['value'] }}" - name: Replace Nordigen Key secret ansible.builtin.replace: path: "$HOME/{{ app }}/.importer.env" regexp: "NORDIGEN_KEY_VALUE" - replace: "{{ lookup('infisical.vault.read_secrets', env_slug='prod', path='/finance', secret_name='NORDIGEN_KEY')['value'] }}" + replace: "{{ lookup('infisical.vault.read_secrets', project_id=infisical_project, env_slug='prod', + path='/finance', secret_name='NORDIGEN_KEY')['value'] }}" - name: Replace SMTP Password secret (importer) ansible.builtin.replace: path: "$HOME/{{ app }}/.importer.env"