Created
January 7, 2025 08:18
-
-
Save arifnd/c7e277bde120648f1504d55e945d6ce9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| map $http_upgrade $connection_upgrade { | |
| default upgrade; | |
| '' close; | |
| } | |
| server { | |
| listen 80; | |
| listen [::]:80; | |
| server_name domain.com; | |
| server_tokens off; | |
| root /var/www/domain.com/public; | |
| index index.php; | |
| charset utf-8; | |
| location /index.php { | |
| try_files /not_exists @octane; | |
| } | |
| location / { | |
| try_files $uri $uri/ @octane; | |
| } | |
| location = /favicon.ico { | |
| access_log off; | |
| log_not_found off; | |
| } | |
| location = /robots.txt { | |
| access_log off; | |
| log_not_found off; | |
| } | |
| access_log off; | |
| error_log /var/log/nginx/domain.com-error.log error; | |
| error_page 404 /index.php; | |
| location @octane { | |
| set $suffix ""; | |
| if ($uri = /index.php) { | |
| set $suffix ?$query_string; | |
| } | |
| proxy_http_version 1.1; | |
| proxy_set_header Host $http_host; | |
| proxy_set_header Scheme $scheme; | |
| proxy_set_header SERVER_PORT $server_port; | |
| proxy_set_header REMOTE_ADDR $remote_addr; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header Upgrade $http_upgrade; | |
| proxy_set_header Connection $connection_upgrade; | |
| proxy_pass http://127.0.0.1:8000$suffix; | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [program:domain.com] | |
| process_name=%(program_name)s_%(process_num)02d | |
| command=/usr/bin/php8.4 /var/www/domain.com/artisan | |
| octane:frankenphp --port=8000 | |
| autostart=true | |
| autorestart=true | |
| user=www-data | |
| numprocs=1 | |
| redirect_stderr=true | |
| stdout_logfile=/var/log/supervisor/domain.com.log |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment