1
0
Fork 0
gopoop.org/foundry.yaml

66 lines
2.1 KiB
YAML
Executable File

---
- name: Setup Foundry
hosts: all
vars_files:
- vault.yaml
- vars.yaml
tasks:
- name: Create Foundry data folder
file:
path: /home/server/foundry_data
state: directory
- name: Run Foundry
docker_container:
name: "{{ stack_prefix_name }}foundry"
recreate: true
restart_policy: unless-stopped
image: felddy/foundryvtt:10.286
hostname: foundry.gopoop.org
init: yes
env:
FOUNDRY_USERNAME: "{{ secret_foundry_username }}"
FOUNDRY_PASSWORD: "{{ secret_foundry_password }}"
FOUNDRY_ADMIN_KEY: "{{ secret_foundry_admin_key }}"
CONTAINER_PRESERVE_CONFIG: "true"
networks:
- name: "{{ stack_prefix_name }}{{ docker_internal_network }}"
# Foundry needs to talk to the outside world to validate the license.
- name: "{{ stack_prefix_name }}{{ docker_external_network }}"
mounts:
- target: /data
source: /home/server/foundry_data
type: bind
state: "{{ container_state }}"
- name: Create Foundry 2 data folder
file:
path: /home/server/foundry_2_data
state: directory
- name: Run Foundry 2
docker_container:
name: "{{ stack_prefix_name }}foundry_2"
recreate: true
restart_policy: unless-stopped
image: felddy/foundryvtt:release-9.269
hostname: foundry2.gopoop.org
init: yes
env:
FOUNDRY_USERNAME: "{{ secret_foundry_username }}"
FOUNDRY_PASSWORD: "{{ secret_foundry_password }}"
FOUNDRY_ADMIN_KEY: "{{ secret_foundry_2_admin_key }}"
CONTAINER_PRESERVE_CONFIG: "true"
networks:
- name: "{{ stack_prefix_name }}{{ docker_internal_network }}"
# Foundry needs to talk to the outside world to validate the license.
- name: "{{ stack_prefix_name }}{{ docker_external_network }}"
mounts:
- target: /data
source: /home/server/foundry_2_data
type: bind
state: "{{ container_state }}"