Skip to content

Commit

Permalink
fix: disabled filament backup plugin and docker deployment updates
Browse files Browse the repository at this point in the history
  • Loading branch information
CS76 committed Dec 12, 2024
1 parent a63931c commit 762b366
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 6 deletions.
2 changes: 0 additions & 2 deletions app/Providers/Filament/AdminPanelProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
use Illuminate\Session\Middleware\StartSession;
use Illuminate\View\Middleware\ShareErrorsFromSession;
use pxlrbt\FilamentSpotlight\SpotlightPlugin;
use ShuvroRoy\FilamentSpatieLaravelBackup\FilamentSpatieLaravelBackupPlugin;
use Stephenjude\FilamentDebugger\DebuggerPlugin;

class AdminPanelProvider extends PanelProvider
Expand All @@ -46,7 +45,6 @@ public function panel(Panel $panel): Panel
FilamentShieldPlugin::make(),
FilamentExceptionsPlugin::make(),
DebuggerPlugin::make(),
FilamentSpatieLaravelBackupPlugin::make(),
SpotlightPlugin::make(),
AdvancedTablesPlugin::make(),
])
Expand Down
32 changes: 32 additions & 0 deletions deployment/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
events {
worker_connections 1024;
}

http {
upstream app_backend {
# Define the replicas of the `app` service
server app:8000;
server app:8000 backup;
}

server {
listen 80;

location / {
# Route traffic to the `app_backend` upstream
proxy_pass http://app_backend;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}

# Optional: Add custom error pages or fallback for failed upstream connections
error_page 502 /502.html;
location = /502.html {
internal;
root /usr/share/nginx/html;
}
}
}
22 changes: 18 additions & 4 deletions docker-compose.prod.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,34 @@
services:
nginx:
image: nginx:alpine
container_name: nginx_lb
ports:
- "80:80"
volumes:
- ./deployment/nginx.conf:/etc/nginx/nginx.conf:ro
networks:
- coconut
depends_on:
- app
app:
image: nfdi4chem/coconut:latest
container_name: coconut_app
env_file:
- .env
deploy:
replicas: 2
update_config:
parallelism: 1
delay: 10s
restart_policy:
condition: on-failure
networks:
- coconut
ports:
- '${APP_PORT:-8000}:8000'
depends_on:
- pgsql
- redis
- cm
worker:
image: nfdi4chem/coconut:latest
container_name: coconut_worker
env_file:
- .env
networks:
Expand Down

0 comments on commit 762b366

Please sign in to comment.