From 29d7aed870e8e96f6791b3671c0e6ffc0c004d55 Mon Sep 17 00:00:00 2001 From: yohan <783b8c87@scimetis.net> Date: Sat, 21 Oct 2023 00:23:30 +0200 Subject: [PATCH] New playbook gen_bootstrap.yml. --- gen_bootstrap.yml | 8 ++++++++ tasks/start.yml | 14 +++++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100755 gen_bootstrap.yml diff --git a/gen_bootstrap.yml b/gen_bootstrap.yml new file mode 100755 index 0000000..f93c706 --- /dev/null +++ b/gen_bootstrap.yml @@ -0,0 +1,8 @@ +--- +- name: gen_bootstrap + hosts: localhost + gather_facts: false + vars_files: main.yml + tasks: + - name: test + shell: echo Hello diff --git a/tasks/start.yml b/tasks/start.yml index 5c1f398..d8308e8 100755 --- a/tasks/start.yml +++ b/tasks/start.yml @@ -228,13 +228,24 @@ delegate_to: 172.17.0.1 become: true +- name: Clone duplicity_playbooks repo + ansible.builtin.git: + repo: 'https://git.scimetis.net/yohan/duplicity_playbooks.git' + dest: "/home/{{ user }}/repository/duplicity_playbooks_temp" + clone: yes + version: dev + update: true + force: true + remote_user: "{{ user }}" + delegate_to: 172.17.0.1 + - name: Start duplicity container community.docker.docker_container: name: duplicity image: "duplicity:{{ tag }}" entrypoint: - "ansible-playbook" - - "gen_bootstrap.yml" + - "/root/duplicity_playbooks/gen_bootstrap.yml" output_logs: true detach: false network_mode: host @@ -247,6 +258,7 @@ - /home/{{ user }}/repository/docker-duplicity-stack/mail_credentials.json:/root/mail_credentials.json:z - /home/{{ user }}/repository/docker-duplicity-stack/id_rsa:/root/.ssh/id_rsa:Z - /home/{{ user }}/repository/docker-duplicity-stack/config:/root/.ssh/config:Z + - /home/{{ user }}/repository/duplicity_playbooks_temp:/root/duplicity_playbooks:Z env: OS_AUTH_URL: "{{ OS_AUTH_URL }}" OS_IDENTITY_API_VERSION: "{{ OS_IDENTITY_API_VERSION }}"