Bump dojo version and some minor cleanup.
This commit is contained in:
parent
3c05eb1caa
commit
281c52363a
@ -1,5 +1,5 @@
|
||||
---
|
||||
samourai_dojo_version: "1.20.0"
|
||||
samourai_dojo_version: "1.21.0"
|
||||
samourai_dojo_onion_service: "{{ lookup('ansible.builtin.env', 'SAMOURAI_DOJO_ONION') | default('_') }}"
|
||||
samourai_dojo_onion_port: 80
|
||||
samourai_dojo_onion_path: data-tor
|
||||
|
@ -5,7 +5,7 @@
|
||||
- ansible_user_id != 'root'
|
||||
fail_msg: "Podman containers are rootless, so please do not run this role as root."
|
||||
|
||||
- name: Dojo | Assert all secrets have been defined.
|
||||
- name: Assert all secrets have been defined.
|
||||
ansible.builtin.assert:
|
||||
that:
|
||||
- item is defined
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
# https://code.samourai.io/dojo/samourai-dojo/-/blob/develop/docker/my-dojo/docker-compose.yaml
|
||||
- name: Dojo | Build image
|
||||
- name: Build image
|
||||
register: podman_image_output
|
||||
containers.podman.podman_image:
|
||||
name: samourai-dojo
|
||||
@ -10,21 +10,20 @@
|
||||
pull: false
|
||||
state: build
|
||||
build:
|
||||
# format: oci
|
||||
file: ~/src/samourai-dojo/docker/my-dojo/node/Dockerfile
|
||||
extra_args: "--build-arg TOR_LINUX_GID=1107"
|
||||
|
||||
- ansible.builtin.debug:
|
||||
var: podman_image_output
|
||||
|
||||
- name: Dojo | Create volumes
|
||||
- name: Create volumes
|
||||
containers.podman.podman_volume:
|
||||
state: present
|
||||
name: "{{ samourai_dojo_onion_path }}"
|
||||
recreate: no
|
||||
when: not samourai_dojo_onion_path.startswith('/')
|
||||
|
||||
- name: Dojo | Create container
|
||||
- name: Create container
|
||||
register: podman_container_output
|
||||
containers.podman.podman_container:
|
||||
debug: no
|
||||
|
@ -1,5 +1,5 @@
|
||||
---
|
||||
- name: Dojo | Clone repository
|
||||
- name: Clone repository
|
||||
ansible.builtin.git:
|
||||
repo: 'https://code.samourai.io/dojo/samourai-dojo.git'
|
||||
dest: ~/src/samourai-dojo
|
||||
@ -8,7 +8,7 @@
|
||||
tags: upgrade
|
||||
|
||||
# install/install-scripts.sh
|
||||
- name: Dojo | Check whether the database has been initialized
|
||||
- name: Check whether the database has been initialized
|
||||
community.mysql.mysql_info:
|
||||
filter:
|
||||
- databases
|
||||
@ -17,7 +17,7 @@
|
||||
login_password: "{{ samourai_dojo_config.MYSQL_PASSWORD }}"
|
||||
register: databases
|
||||
|
||||
- name: Dojo | Initialize database
|
||||
- name: Initialize database
|
||||
community.mysql.mysql_db:
|
||||
name: samourai
|
||||
state: import
|
||||
@ -26,20 +26,20 @@
|
||||
login_password: "{{ samourai_dojo_config.MYSQL_PASSWORD }}"
|
||||
when: databases.databases.samourai.size == 0
|
||||
|
||||
- name: Dojo | Initialize the maintenace tool
|
||||
- name: Initialize the maintenace tool
|
||||
ansible.builtin.copy:
|
||||
remote_src: yes
|
||||
src: "~/src/samourai-dojo/static/admin/conf/index-{{ samourai_dojo_config.COMMON_BTC_NETWORK }}.js"
|
||||
dest: ~/src/samourai-dojo/static/admin/conf/index.js
|
||||
|
||||
- block:
|
||||
- name: Dojo | Ensure onoion services directory exists
|
||||
- name: Ensure the onion services directory exists
|
||||
ansible.builtin.file:
|
||||
path: "{{ samourai_dojo_onion_path }}"
|
||||
state: directory
|
||||
mode: '0755'
|
||||
|
||||
- name: Dojo | Write the hostname to a file in the samourai_dojo_onion_path
|
||||
- name: Write the hostname to a file in the samourai_dojo_onion_path
|
||||
ansible.builtin.lineinfile:
|
||||
path: "{{ samourai_dojo_onion_path }}/hostname"
|
||||
line: "{{ samourai_dojo_onion_service }}"
|
||||
|
Loading…
Reference in New Issue
Block a user