Add Podman files

This commit is contained in:
2025-02-07 20:57:54 +00:00
parent a942c094b3
commit 987cb52443
7 changed files with 381 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
upstream django {
#server app:8000;
server unix:///var/run/uwsgi-gia.sock;
}
server {
listen 9999;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /conf;
}
location / {
include /etc/nginx/uwsgi_params; # the uwsgi_params file you installed
uwsgi_pass django;
uwsgi_param Host $host;
uwsgi_param X-Real-IP $remote_addr;
uwsgi_param X-Forwarded-For $proxy_add_x_forwarded_for;
uwsgi_param X-Forwarded-Proto $http_x_forwarded_proto;
}
}

View File

@@ -0,0 +1,24 @@
upstream django {
server app:8000;
#server unix:///var/run/socks/app.sock;
}
server {
listen 9999;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /conf;
}
location / {
include /etc/nginx/uwsgi_params; # the uwsgi_params file you installed
uwsgi_pass django;
uwsgi_param Host $host;
uwsgi_param X-Real-IP $remote_addr;
uwsgi_param X-Forwarded-For $proxy_add_x_forwarded_for;
uwsgi_param X-Forwarded-Proto $http_x_forwarded_proto;
}
}

3
docker/redis.conf Normal file
View File

@@ -0,0 +1,3 @@
unixsocket /var/run/gia-redis.sock
unixsocketperm 777
port 0

22
docker/uwsgi.ini Normal file
View File

@@ -0,0 +1,22 @@
[uwsgi]
chdir=/code
module=app.wsgi:application
env=DJANGO_SETTINGS_MODULE=app.settings
master=1
pidfile=/tmp/project-master.pid
#socket=0.0.0.0:8000
socket=/var/run/uwsgi-gia.sock
# socket 777
chmod-socket=777
harakiri=200
#max-requests=100000
# Set a lower value for max-requests to prevent memory leaks from building up over time
max-requests=1000
# Ensure old worker processes are cleaned up properly
reload-on-as=512
reload-on-rss=256
vacuum=1
home=/venv
processes=4
threads=2
log-level=debug