main.yml (1945B)
1 --- 2 # Event/regional exchange for hacktivism GOA + systemd. 3 # Flow = taler-deployment/regional-currency/setup-exchange.sh 4 # packages → config → coins → db → systemctl taler-exchange.target 5 # → optional offline → /config + /keys 6 # 7 # NOT included: nginx, certbot, nexus, EBICS, IBAN, KYC, snapshot/manual start. 8 9 - name: Detect init model 10 ansible.builtin.command: cat /proc/1/comm 11 register: init_comm 12 changed_when: false 13 14 - name: Set systemd_available fact 15 ansible.builtin.set_fact: 16 systemd_available: "{{ init_comm.stdout | trim == 'systemd' }}" 17 18 - name: Require systemd (regional-currency model) 19 ansible.builtin.fail: 20 msg: >- 21 PID1 is '{{ init_comm.stdout | trim }}', not systemd. 22 Recreate the container with run-container-koopa.sh 23 (podman --systemd=always, image :base, /usr/sbin/init). 24 Snapshot/sleep-infinity images are not supported by this role. 25 when: 26 - require_systemd | bool 27 - not (systemd_available | bool) 28 29 - name: Fail if conversion requested 30 ansible.builtin.fail: 31 msg: "do_conversion is not supported — use regional-currency host install for fiat/EBICS" 32 when: do_conversion | bool 33 34 - name: Packages 35 ansible.builtin.include_tasks: packages.yml 36 37 - name: Site config (regional setup.conf + GOA overrides + wire + terms) 38 ansible.builtin.include_tasks: site_config.yml 39 40 - name: Denominations 41 ansible.builtin.include_tasks: coins.yml 42 43 - name: Postgres (systemd) 44 ansible.builtin.include_tasks: postgres.yml 45 46 - name: Database schema 47 ansible.builtin.include_tasks: db.yml 48 49 - name: Systemd drop-ins for rootless podman 50 ansible.builtin.include_tasks: systemd_container.yml 51 52 - name: Start exchange (systemctl, regional-currency) 53 ansible.builtin.include_tasks: start.yml 54 55 - name: Offline keys / wire enable (regional) 56 ansible.builtin.include_tasks: offline.yml 57 when: do_offline | bool 58 59 - name: Health checks 60 ansible.builtin.include_tasks: health.yml