turned base into transfer.sh deployment

This commit is contained in:
Bryan Joshua Pedini 2023-12-21 08:32:20 +01:00
parent 5ed1af1f7f
commit 47e3a68514
3 changed files with 100 additions and 6 deletions

View File

@ -1,2 +1,2 @@
# Base App Deployment # Transfer.sh Deployment
This is the base on which (almost) every deployment is sort-of-based on. based on [dutchcoders/transfer.sh](https://github.com/dutchcoders/transfer.sh)

View File

@ -1,7 +1,52 @@
--- ---
services: services:
app: transfer:
image: dutchcoders/transfer.sh:${TSH_VERSION}
command: --provider ${TSH_PROVIDER}
restart: unless-stopped restart: unless-stopped
environment:
- LISTENER=${TSH_LISTENER}
- PROFILE_LISTENER=${TSH_PROFILE_LISTENER}
- FORCE_HTTPS=${TSH_FORCE_HTTPS}
- TLS_LISTENER=${TSH_TLS_LISTENER}
- TLS_LISTENER_ONLY=${TSH_TLS_LISTENER_ONLY}
- TLS_CERT_FILE=${TSH_TLS_CERT_FILE}
- TLS_PRIVATE_KEY=${TSH_TLS_PRIVATE_KEY}
- HTTP_AUTH_USER=${TSH_HTTP_AUTH_USER}
- HTTP_AUTH_PASS=${TSH_HTTP_AUTH_PASS}
- HTTP_AUTH_HTPASSWD=${TSH_HTTP_AUTH_HTPASSWD}
- HTTP_AUTH_IP_WHITELIST=${TSH_HTTP_AUTH_IP_WHITELIST}
- IP_WHITELIST=${TSH_IP_WHITELIST}
- IP_BLACKLIST=${TSH_IP_BLACKLIST}
- TEMP_PATH=${TSH_TEMP_PATH}
- PROXY_PATH=${TSH_PROXY_PATH}
- PROXY_PORT=${TSH_PROXY_PORT}
- EMAIL_CONTACT=${TSH_EMAIL_CONTACT}
- GA_KEY=${TSH_GA_KEY}
- USERVOICE_KEY=${TSH_USERVOICE_KEY}
- AWS_ACCESS_KEY=${TSH_AWS_ACCESS_KEY}
- AWS_SECRET_KEY=${TSH_AWS_SECRET_KEY}
- BUCKET=${TSH_BUCKET}
- S3_ENDPOINT=${TSH_S3_ENDPOINT}
- S3_REGION=${TSH_S3_REGION}
- S3_NO_MULTIPART=${TSH_S3_NO_MULTIPART}
- S3_PATH_STYLE=${TSH_S3_PATH_STYLE}
- STORJ_ACCESS=${TSH_STORJ_ACCESS}
- STORJ_BUCKET=${TSH_STORJ_BUCKET}
- BASEDIR=${TSH_BASEDIR}
- GDRIVE_CLIENT_JSON_FILEPATH=${TSH_GDRIVE_CLIENT_JSON_FILEPATH}
- GDRIVE_LOCAL_CONFIG_PATH=${TSH_GDRIVE_LOCAL_CONFIG_PATH}
- GDRIVE_CHUNK_SIZE=${TSH_GDRIVE_CHUNK_SIZE}
- HOSTS=${TSH_HOSTS}
- LOG=${TSH_LOG}
- CORS_DOMAINS=${TSH_CORS_DOMAINS}
- CLAMAV_HOST=${TSH_CLAMAV_HOST}
- PERFORM_CLAMAV_PRESCAN=${TSH_PERFORM_CLAMAV_PRESCAN}
- RATE_LIMIT=${TSH_RATE_LIMIT}
- MAX_UPLOAD_SIZE=${TSH_MAX_UPLOAD_SIZE}
- PURGE_DAYS=${TSH_PURGE_DAYS}
- PURGE_INTERVAL=${TSH_PURGE_INTERVAL}
- RANDOM_TOKEN_LENGTH=${TSH_RANDOM_TOKEN_LENGTH}
labels: labels:
### Section Træfik ### Section Træfik
- traefik.enable=${TRAEFIK_ENABLED} - traefik.enable=${TRAEFIK_ENABLED}
@ -29,6 +74,8 @@ services:
- diun.exclude_tags=${DIUN_EXCLUDE} - diun.exclude_tags=${DIUN_EXCLUDE}
networks: networks:
- traefik - traefik
volumes:
- ${TSH_DATA}:/data
networks: networks:
traefik: traefik:

View File

@ -1,10 +1,10 @@
# Træfik # Træfik
TRAEFIK_ENABLED=true TRAEFIK_ENABLED=true
TRAEFIK_NETWORK=traefik TRAEFIK_NETWORK=traefik
TRAEFIK_ROUTER=app_example_com TRAEFIK_ROUTER=transfer_example_com
TRAEFIK_SERVICE=app_example_com TRAEFIK_SERVICE=tramsfer_example_com
TRAEFIK_SERVICE_PORT=80 TRAEFIK_SERVICE_PORT=80
TRAEFIK_MATCHRULE=Host(`app.example.com`) TRAEFIK_MATCHRULE=Host(`transfer.example.com`)
TRAEFIK_TLSENABLED=true TRAEFIK_TLSENABLED=true
TRAEFIK_CERTRESOLVER=letsencrypt TRAEFIK_CERTRESOLVER=letsencrypt
TRAEFIK_HTTP_MIDDLEWARES=http-to-https TRAEFIK_HTTP_MIDDLEWARES=http-to-https
@ -16,3 +16,50 @@ DIUN_WATCHREPO=true
DIUN_SORTALGO=semver DIUN_SORTALGO=semver
DIUN_INCLUDE= DIUN_INCLUDE=
DIUN_EXCLUDE= DIUN_EXCLUDE=
# Transfer.sh
TSH_VERSION=latest
TSH_DATA=./data
TSH_PROVIDER=local
TSH_LISTENER=:80
TSH_PROFILE_LISTENER=:6060
TSH_FORCE_HTTPS=false
TSH_TLS_LISTENER=:443
TSH_TLS_LISTENER_ONLY=
TSH_TLS_CERT_FILE=
TSH_TLS_PRIVATE_KEY=
TSH_HTTP_AUTH_USER=
TSH_HTTP_AUTH_PASS=
TSH_HTTP_AUTH_HTPASSWD=
TSH_HTTP_AUTH_IP_WHITELIST=
TSH_IP_WHITELIST=
TSH_IP_BLACKLIST=
TSH_TEMP_PATH=
TSH_PROXY_PATH=
TSH_PROXY_PORT=
TSH_EMAIL_CONTACT=
TSH_GA_KEY=
TSH_USERVOICE_KEY=
TSH_AWS_ACCESS_KEY=
TSH_AWS_SECRET_KEY=
TSH_BUCKET=
TSH_S3_ENDPOINT=
TSH_S3_REGION=eu-west-1
TSH_S3_NO_MULTIPART=false
TSH_S3_PATH_STYLE=false
TSH_STORJ_ACCESS=
TSH_STORJ_BUCKET=
TSH_BASEDIR=/data
TSH_GDRIVE_CLIENT_JSON_FILEPATH=
TSH_GDRIVE_LOCAL_CONFIG_PATH=
TSH_GDRIVE_CHUNK_SIZE=
TSH_HOSTS=
TSH_LOG=
TSH_CORS_DOMAINS=
TSH_CLAMAV_HOST=
TSH_PERFORM_CLAMAV_PRESCAN=
TSH_RATE_LIMIT=
TSH_MAX_UPLOAD_SIZE=
TSH_PURGE_DAYS=7
TSH_PURGE_INTERVAL=6
TSH_RANDOM_TOKEN_LENGTH=6