admin 2 months ago
commit
c263ca2a47
6 changed files with 57 additions and 0 deletions
  1. 4 0
      .env.template
  2. 3 0
      .gitignore
  3. 17 0
      README.md
  4. 0 0
      data/frontend/download.html
  5. 0 0
      data/frontend/index.html
  6. 33 0
      docker-compose.yml

+ 4 - 0
.env.template

@@ -0,0 +1,4 @@
+HTTP_AUTH_USER=PutYourUsernameHere
+HTTP_AUTH_PASS=PutYouPasswordHere
+VIRTUAL_HOST=transfer.example.com
+RANDOM_TOKEN_LENGTH=20

+ 3 - 0
.gitignore

@@ -0,0 +1,3 @@
+.env
+data/files/
+data/temp/

+ 17 - 0
README.md

@@ -0,0 +1,17 @@
+# Transfer.sh
+
+Simple to use file sharing service supporting http upload.
+Learn more: https://github.com/dutchcoders/transfer.sh/
+
+## Dependencies
+- reverse-proxy
+
+## Setup
+```
+# Configuration
+cp .env.template .env && vi .env
+
+# Create data folders with proper permissions
+mkdir -p      ./data/files ./data/temp
+chown -R 5000:5000 ./data/
+```

+ 0 - 0
data/frontend/download.html


+ 0 - 0
data/frontend/index.html


+ 33 - 0
docker-compose.yml

@@ -0,0 +1,33 @@
+version: "3.9"
+services:
+  transfer-sh:
+    container_name: transfer-sh
+    image: dutchcoders/transfer.sh:latest-noroot
+    command: "--provider local"
+
+    restart: on-failure:3
+    mem_limit: 200M
+
+    volumes:
+      - ./data/temp:/mnt/transfer-sh/temp:rw
+      - ./data/files:/mnt/transfer-sh/files:rw
+      - ./data/frontend:/mnt/transfer-sh/frontend:rw
+      
+    environment: 
+      HTTP_AUTH_USER:      ${HTTP_AUTH_USER}
+      HTTP_AUTH_PASS:      ${HTTP_AUTH_PASS}
+      TEMP_PATH:           /mnt/transfer-sh/temp
+      BASEDIR:             /mnt/transfer-sh/files
+      WEB_PATH:            /mnt/transfer-sh/frontend
+      RANDOM_TOKEN_LENGTH: ${RANDOM_TOKEN_LENGTH}
+      VIRTUAL_HOST:        ${VIRTUAL_HOST}
+      LETSENCRYPT_HOST:    ${VIRTUAL_HOST}
+      LETSENCRYPT_EMAIL:   webmaster@${VIRTUAL_HOST}
+
+    networks:
+      - reverse-proxy_default
+
+networks:
+  reverse-proxy_default:
+    external: true
+