This commit is contained in:
2026-04-13 11:16:13 +02:00
parent bbd5690d72
commit 30125aa77b
4 changed files with 41 additions and 19 deletions

View File

@@ -1,18 +1,17 @@
# Database — din MySQL server # Database
DATABASE_URL=mysql+pymysql://BRUGER:KODEORD@mysql.ckvist.lan:3306/linedance DATABASE_URL=mysql+pymysql://linedanceplayer:KODEORD@mysql.ckvist.lan:3306/linedanceplayer
# JWT — generer med: python -c "import secrets; print(secrets.token_hex(32))" # Sikkerhed — generer med: python3 -c "import secrets; print(secrets.token_hex(32))"
SECRET_KEY=skift-denne-til-en-lang-tilfaeldig-streng-mindst-32-tegn SECRET_KEY=skift-denne-til-en-rigtig-nøgle
ACCESS_TOKEN_EXPIRE_MINUTES=10080 ACCESS_TOKEN_EXPIRE_MINUTES=10080
# Mail — din SMTP server # Mail
MAIL_HOST=din-smtp-server MAIL_HOST=mail.miraca.dk
MAIL_PORT=587 MAIL_PORT=587
MAIL_FROM=noreply@din-domæne.dk MAIL_FROM=noreply@linedanceplayer.dk
MAIL_USERNAME= MAIL_USERNAME=noreply@linedanceplayer.dk
MAIL_PASSWORD= MAIL_PASSWORD=skift-dette
MAIL_TLS=true MAIL_TLS=true
# URL til verificerings-links i mails # URL til denne server (bruges i verificerings-mails)
# Skal være den adresse din Docker-container er tilgængelig på BASE_URL=http://localhost:8000
BASE_URL=http://din-server-ip:8000

18
linedance-api/.gitignore vendored Normal file
View File

@@ -0,0 +1,18 @@
# Python
__pycache__/
*.py[cod]
*.pyo
.Python
venv/
.venv/
*.egg-info/
# Environment
.env
# IDE
.vscode/
.idea/
# Logs
*.log

View File

@@ -3,16 +3,21 @@ services:
api: api:
build: . build: .
restart: always restart: always
ports: expose:
- "8000:8000" - "8000"
env_file: env_file:
- .env - .env
volumes: networks:
- .:/app - linedance
adminer: adminer:
image: adminer image: adminer
restart: always restart: always
ports: expose:
- "8080:8080" - "8080"
networks:
- linedance
networks:
linedance:
name: linedance

View File

@@ -21,4 +21,4 @@ except Exception as e:
sleep 2 sleep 2
done done
exec uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload exec uvicorn app.main:app --host 0.0.0.0 --port 8000