diff options
| author | Yuqian Yang <crupest@crupest.life> | 2025-02-24 02:18:20 +0800 | 
|---|---|---|
| committer | Yuqian Yang <crupest@crupest.life> | 2025-02-26 02:21:41 +0800 | 
| commit | 0874dd5d5652f7d710d98329ba111fd69e7d8fce (patch) | |
| tree | d07e51b0f743d796d8e680530d2d2811565dac2b /services/templates | |
| parent | 46e66fefdf1affe6062ab498a28d766ef0e5d0c3 (diff) | |
| download | crupest-0874dd5d5652f7d710d98329ba111fd69e7d8fce.tar.gz crupest-0874dd5d5652f7d710d98329ba111fd69e7d8fce.tar.bz2 crupest-0874dd5d5652f7d710d98329ba111fd69e7d8fce.zip | |
feat(www): YEAH!
Diffstat (limited to 'services/templates')
| -rw-r--r-- | services/templates/docker-compose.yaml.template | 16 | ||||
| -rw-r--r-- | services/templates/nginx/conf.d/mail.conf.template | 4 | ||||
| -rw-r--r-- | services/templates/nginx/conf.d/root.conf.template | 8 | 
3 files changed, 15 insertions, 13 deletions
| diff --git a/services/templates/docker-compose.yaml.template b/services/templates/docker-compose.yaml.template index d6640ef..2f6a748 100644 --- a/services/templates/docker-compose.yaml.template +++ b/services/templates/docker-compose.yaml.template @@ -1,19 +1,11 @@  services: -  blog: -    pull_policy: build -    build: -      context: ./@@CRUPEST_DOCKER_DIR@@/blog -      dockerfile: Dockerfile -      pull: true -    volumes: -      - "blog-public:/public" -    restart: on-failure:3 -    nginx:      pull_policy: build      build:        context: ./@@CRUPEST_DOCKER_DIR@@/nginx +      additional_contexts: +        - www=./www        dockerfile: Dockerfile        pull: true      ports: @@ -27,7 +19,6 @@ services:        - "./@@CRUPEST_DATA_CERTBOT_DIR@@/webroot:/srv/acme:ro"        - "./@@CRUPEST_DATA_CERTBOT_DIR@@/data:/var/lib/letsencrypt"        - "./@@CRUPEST_DATA_CERTBOT_DIR@@/webroot:/var/www/certbot" -      - "blog-public:/srv/www/blog:ro"      restart: on-failure:3    v2ray: @@ -52,7 +43,7 @@ services:        - "CRUPEST_AUTO_BACKUP_COS_ENDPOINT=@@CRUPEST_AUTO_BACKUP_COS_ENDPOINT@@"        - "CRUPEST_AUTO_BACKUP_COS_BUCKET=@@CRUPEST_AUTO_BACKUP_COS_BUCKET@@"        - "CRUPEST_AUTO_BACKUP_COS_SECRET_ID=@@CRUPEST_AUTO_BACKUP_COS_SECRET_ID@@" -      - "CRUPEST_AUTO_BACKUP_COS_SECRET_KEY=@@CRUPEST_AUTO_BACKUP_COS_SECRET_KEY@@"   +      - "CRUPEST_AUTO_BACKUP_COS_SECRET_KEY=@@CRUPEST_AUTO_BACKUP_COS_SECRET_KEY@@"      volumes:        - "./data:/data"      restart: on-failure:3 @@ -142,5 +133,4 @@ services:        - TRUSTED_PROXIES=*  volumes: -  blog-public:    roundcubemail-temp: diff --git a/services/templates/nginx/conf.d/mail.conf.template b/services/templates/nginx/conf.d/mail.conf.template index 2eb53d7..c115c2e 100644 --- a/services/templates/nginx/conf.d/mail.conf.template +++ b/services/templates/nginx/conf.d/mail.conf.template @@ -2,6 +2,10 @@ server {      server_name mail.@@CRUPEST_DOMAIN@@;      include common/https-listen; +    location = /robots.txt { +        root /srv/mail; +    } +      location / {          include common/proxy-common;          proxy_pass http://roundcubemail:80/; diff --git a/services/templates/nginx/conf.d/root.conf.template b/services/templates/nginx/conf.d/root.conf.template index 3ea97d9..dd223c2 100644 --- a/services/templates/nginx/conf.d/root.conf.template +++ b/services/templates/nginx/conf.d/root.conf.template @@ -17,6 +17,14 @@ server {          proxy_pass http://git-server:80;      } +    location = /github { +        return 301 @@CRUPEST_GITHUB@@; +    } + +    location = /github/ { +        return 301 @@CRUPEST_GITHUB@@; +    } +      location /_@@CRUPEST_V2RAY_PATH@@ {          if ($http_upgrade != "websocket") {              return 404; | 
