Implemented assets server

This commit is contained in:
2025-03-20 03:47:12 +01:00
parent 836a3e0238
commit 87ca1ccc11
23 changed files with 54 additions and 34 deletions

View File

@@ -0,0 +1,6 @@
# Nginx Homepage Role
This Ansible role configures an Nginx server to serve a static homepage. It handles domain configuration, SSL certificate retrieval with Let's Encrypt.
## Author Information
This role was created in 2023 by [Kevin Veen Birkenbach](https://www.veen.world/).

View File

@@ -0,0 +1,2 @@
dependencies:
- nginx-serve-files

View File

@@ -0,0 +1,7 @@
---
- name: "Recursively copy files from local '{{ source_directory }}' to '{{ target_directory }}'"
ansible.builtin.copy:
src: "{{ source_directory }}"
dest: "{{ target_directory }}"
owner: "{{ nginx.user }}"
group: "{{ nginx.user }}"

View File

@@ -0,0 +1,3 @@
application_id: "assets_server" # Application identifier
source_directory: "{{ applications[application_id].source_directory }}/" # Source directory from which the files are coming from
target_directory: "{{ nginx.directories.data.files }}assets" # Directory to which the files will be copied