Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scale the uwsgi container #399

Merged
merged 2 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion dockerize/.env.template
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,7 @@ EMAIL_HOST_PASSWORD=''
DEFAULT_PLUGINS_SITE='https://plugins.qgis.org/'

# ENV: debug or prod
QGISPLUGINS_ENV=debug
QGISPLUGINS_ENV=debug

# Ldap
ENABLE_LDAP=True
2 changes: 1 addition & 1 deletion dockerize/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ web: db
@echo "------------------------------------------------------------------"
@echo "Running in production mode"
@echo "------------------------------------------------------------------"
@docker compose -p $(PROJECT_ID) up -d uwsgi web worker beat
@docker compose -p $(PROJECT_ID) up -d --scale uwsgi=2 web worker beat

dbbackups: db
@echo
Expand Down
3 changes: 1 addition & 2 deletions dockerize/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
version: '3.8'
volumes:
postgres_data:
rabbitmq:
Expand Down Expand Up @@ -26,7 +25,6 @@ services:
restart: unless-stopped

uwsgi: &uwsgi-common
container_name: qgis-plugins-uwsgi-common
build:
context: ${PWD}/../
dockerfile: dockerize/docker/Dockerfile
Expand All @@ -43,6 +41,7 @@ services:
- VIRTUAL_HOST=${VIRTUAL_HOST:-plugins.kartoza.com}
- VIRTUAL_PORT=${VIRTUAL_PORT:-8080}
- DEBUG=${DEBUG:-False}
- ENABLE_LDAP=${ENABLE_LDAP:-False}
- RABBITMQ_HOST=${RABBITMQ_HOST:-rabbitmq}
- BROKER_URL=amqp://rabbitmq:5672
- EMAIL_BACKEND=${EMAIL_BACKEND}
Expand Down
2 changes: 1 addition & 1 deletion dockerize/docker/uwsgi.conf
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ logger = file:/var/log/uwsgi-errors.log
#uid = 1000
#gid = 1000
memory-report = true
harakiri = 2000
harakiri = 50
listen = 127