diff options
| author | Joe Carstairs <me@joeac.net> | 2026-08-12 16:29:14 +0100 |
|---|---|---|
| committer | Joe Carstairs <me@joeac.net> | 2026-08-12 16:29:14 +0100 |
| commit | 96877bf48ae0920a3439dc3f7866638df4cc633c (patch) | |
| tree | be90f64027e869228ef3645df19c9e74d5e194c2 | |
| parent | 7a47d09292ac3e603f2701d1517c81108c1a7ac7 (diff) | |
ansible: pulls out src_dir var
| -rw-r--r-- | ansible/roles/etherpad/tasks/main.yml | 6 | ||||
| -rw-r--r-- | ansible/roles/etherpad/templates/openrc/etherpad | 2 | ||||
| -rw-r--r-- | ansible/roles/http/tasks/main.yml | 14 | ||||
| -rw-r--r-- | ansible/vars/common.yml | 2 | ||||
| -rw-r--r-- | ansible/vars/etherpad.yml | 1 |
5 files changed, 12 insertions, 13 deletions
diff --git a/ansible/roles/etherpad/tasks/main.yml b/ansible/roles/etherpad/tasks/main.yml index 8709049..185fe51 100644 --- a/ansible/roles/etherpad/tasks/main.yml +++ b/ansible/roles/etherpad/tasks/main.yml @@ -16,7 +16,7 @@ register: etherpad_src ansible.builtin.git: repo: https://github.com/ether/etherpad.git - dest: "{{ etherpad_src_dir }}" + dest: "{{ src_dir }}/etherpad" depth: 1 version: master @@ -24,14 +24,14 @@ register: etherpad_settings ansible.builtin.template: src: settings.json - dest: "{{ etherpad_src_dir }}/settings.json" + dest: "{{ src_dir }}/etherpad/settings.json" mode: "640" - name: Install etherpad dependencies register: etherpad_dependencies changed_when: "'Already up to date' not in etherpad_dependencies.stdout" ansible.builtin.command: - chdir: "{{ etherpad_src_dir }}" + chdir: "{{ src_dir }}/etherpad" cmd: pnpm install - name: Install etherpad service diff --git a/ansible/roles/etherpad/templates/openrc/etherpad b/ansible/roles/etherpad/templates/openrc/etherpad index 36e36f0..f5f7260 100644 --- a/ansible/roles/etherpad/templates/openrc/etherpad +++ b/ansible/roles/etherpad/templates/openrc/etherpad @@ -9,7 +9,7 @@ start() --env NODE_ENV={{ etherpad_node_env }} \ --exec /usr/bin/pnpx \ --background \ - --chdir {{ etherpad_src_dir }} \ + --chdir {{ src_dir }}/etherpad \ --stdout /var/log/etherpad.log \ --stderr /var/log/etherpad.log \ --make-pidfile \ diff --git a/ansible/roles/http/tasks/main.yml b/ansible/roles/http/tasks/main.yml index 1bed1a9..7676633 100644 --- a/ansible/roles/http/tasks/main.yml +++ b/ansible/roles/http/tasks/main.yml @@ -62,13 +62,13 @@ - name: Checkout joeac.net source code ansible.builtin.git: repo: https://git.joeac.net/joeac/joeac.net.git - dest: "{{ joeacnet_src_dir }}" + dest: "{{ src_dir }}/joeac.net" depth: 1 version: main - name: Build joeac.net website community.general.make: - chdir: "{{ joeacnet_src_dir }}/http" + chdir: "{{ src_dir }}/joeac.net/http" - name: Create joeac.net public directory ansible.builtin.file: @@ -80,29 +80,29 @@ - name: Configure website PHP with config.ini ansible.builtin.template: src: config.ini - dest: "{{ joeacnet_src_dir }}/http/config.ini" + dest: "{{ src_dir }}/joeac.net/http/config.ini" - name: Symlink config.ini ansible.builtin.file: - src: "{{ joeacnet_src_dir }}/http/config.ini" + src: "{{ src_dir }}/joeac.net/http/config.ini" dest: "{{ http_files_dir }}/config.ini" state: link - name: Symlink vendor to public directory ansible.builtin.file: - src: "{{ joeacnet_src_dir }}/http/vendor" + src: "{{ src_dir }}/joeac.net/http/vendor" dest: "{{ http_files_dir }}/vendor" state: link - name: Symlink php to public directory ansible.builtin.file: - src: "{{ joeacnet_src_dir }}/http/php" + src: "{{ src_dir }}/joeac.net/http/php" dest: "{{ http_files_dir }}/php" state: link - name: Symlink html to public directory ansible.builtin.file: - src: "{{ joeacnet_src_dir }}/http/out" + src: "{{ src_dir }}/joeac.net/http/out" dest: "{{ http_files_dir }}/html" state: link diff --git a/ansible/vars/common.yml b/ansible/vars/common.yml index b0d9030..20a268f 100644 --- a/ansible/vars/common.yml +++ b/ansible/vars/common.yml @@ -1,4 +1,4 @@ -joeacnet_src_dir: /usr/share/src/joeac.net +src_dir: /usr/share/src services: actualbudget: diff --git a/ansible/vars/etherpad.yml b/ansible/vars/etherpad.yml index 040688a..e9148d7 100644 --- a/ansible/vars/etherpad.yml +++ b/ansible/vars/etherpad.yml @@ -1,4 +1,3 @@ -etherpad_src_dir: /usr/share/src/etherpad etherpad_node_env: production etherpad_admin_password: !vault | $ANSIBLE_VAULT;1.2;AES256;ansible |
