diff --git a/FEATURE_BRANCH.md b/FEATURE_BRANCH.md index e895340..bb5474f 100644 --- a/FEATURE_BRANCH.md +++ b/FEATURE_BRANCH.md @@ -15,16 +15,16 @@ git push -u origin feature/mein-experiment ### 3. Feature Version testen ```bash -# Feature Version starten (Port 3001) +# Feature Version starten (ersetzt Stable Version) docker-compose -f docker-compose.feature.yml up -d -# Hauptversion läuft weiter auf Port 3000 -# Feature Version läuft auf Port 3001 +# Beide Versionen verwenden Port 8199 +# Nightly Version zeigt "Nightly" Badge im Header ``` ### 4. In Portainer -- **Hauptversion:** `flex420/discordsoundbot-vib:latest` (Port 3000) -- **Feature Version:** `flex420/discordsoundbot-vib:feature-nightly` (Port 3001) +- **Stable Version:** `flex420/discordsoundbot-vib:latest` (Port 8199) +- **Nightly Version:** `flex420/discordsoundbot-vib:feature-nightly` (Port 8199) ### 5. Mergen wenn bereit ```bash @@ -42,7 +42,7 @@ git branch -d feature/mein-experiment - `:sha-abc123` - Spezifischer Commit ## Portainer Setup -1. **Hauptcontainer:** Port 3000, Image `:latest` -2. **Feature Container:** Port 3001, Image `:feature-nightly` -3. **Testing:** Feature auf Port 3001 testen +1. **Stable Container:** Port 8199, Image `:latest` +2. **Nightly Container:** Port 8199, Image `:feature-nightly` +3. **Testing:** Nightly Version zeigt "Nightly" Badge im Header 4. **Deployment:** Wenn gut, Feature in main mergen diff --git a/docker-compose.feature.yml b/docker-compose.feature.yml index 909cee5..5f57f83 100644 --- a/docker-compose.feature.yml +++ b/docker-compose.feature.yml @@ -6,12 +6,13 @@ services: container_name: jukebox-feature restart: unless-stopped ports: - - "3001:3000" # Anderer Port für Feature Testing + - "8199:8080" # Gleicher Port wie Stable environment: - DISCORD_TOKEN=${DISCORD_TOKEN} - CLIENT_ID=${CLIENT_ID} - GUILD_ID=${GUILD_ID} - ADMIN_PWD=${ADMIN_PWD} + - REACT_APP_VERSION=nightly volumes: - ./data/sounds:/data/sounds - ./data/uploads:/data/uploads diff --git a/docker-compose.yml b/docker-compose.yml index 77c3269..9674592 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,6 +6,8 @@ services: - "8199:8080" env_file: - .env + environment: + - REACT_APP_VERSION=stable volumes: - ./data/sounds:/data/sounds restart: unless-stopped diff --git a/web/src/App.tsx b/web/src/App.tsx index 1ae2f2f..22ff5b9 100644 --- a/web/src/App.tsx +++ b/web/src/App.tsx @@ -179,7 +179,7 @@ export default function App() {

Jukebox 420 - {window.location.hostname.includes('localhost') && window.location.port === '3001' && ( + {process.env.REACT_APP_VERSION === 'nightly' && ( Nightly )}