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

increase nginx buffer size when proxifying keycloak #637

Merged
merged 4 commits into from
Feb 14, 2025

Conversation

lunika
Copy link
Member

@lunika lunika commented Feb 14, 2025

Purpose

Nginx is used to proxify keycloak in our development configuration. When
a new user is created keycloak is send a large amount of headers in its
response and the default nginx config is not enough to handle this
amount of headers. We have to increase the proxy buffer size to handle
them.

We all remove the usage of dockerize in this PR to use healthcheck in docker compose services.
And then change all make run commands. The run command is starting everything. The run-back
command is starting all services needed to use the backend application
and then the run-frontend starts only the frontend-dev service.

Proposal

  • increase nginx buffer size when proxifying keycloak
  • remove usage of dockerize
  • make run command starting everything

@lunika lunika added bug Something isn't working enhancement New feature or request labels Feb 14, 2025
@lunika lunika self-assigned this Feb 14, 2025
@lunika lunika force-pushed the fix/keycloak-create-user branch from d9be049 to 906c567 Compare February 14, 2025 11:55
Comment on lines -92 to -111
- name: Install Dockerize
run: |
curl -sSL https://github.com/jwilder/dockerize/releases/download/v0.8.0/dockerize-linux-amd64-v0.8.0.tar.gz | sudo tar -C /usr/local/bin -xzv

- name: Wait for services to be ready
run: |
printf "Minio check...\n"
dockerize -wait tcp://localhost:9000 -timeout 20s
printf "Keyclock check...\n"
dockerize -wait tcp://localhost:8080 -timeout 20s
printf "Server collaboration check...\n"
dockerize -wait tcp://localhost:4444 -timeout 20s
printf "Ngnix check...\n"
dockerize -wait tcp://localhost:8083 -timeout 20s
printf "DRF check...\n"
dockerize -wait tcp://localhost:8071 -timeout 20s
printf "Postgres Keyclock check...\n"
dockerize -wait tcp://localhost:5433 -timeout 20s
printf "Postgres back check...\n"
dockerize -wait tcp://localhost:15432 -timeout 20s
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It solves some flakiness, but let's see.

@lunika lunika force-pushed the fix/keycloak-create-user branch 2 times, most recently from 160ec77 to 08e45d8 Compare February 14, 2025 17:44
@lunika lunika enabled auto-merge (rebase) February 14, 2025 17:45
Nginx is used to proxify keycloak in our development configuration. When
a new user is created keycloak is send a large amount of headers in its
response and the default nginx config is not enough to handle this
amount of headers. We have to increase the proxy buffer size to handle
them.
We remove dockerize and use healthcheck on docker compose services
instead.
The run command is not starting the frontend application. We change the
run commands. The run command is strating everything. The run-backend
command is starting all services needed to use the backend application.
The frontend-dev service is in fact using the production image. We
rename it in frontend accordingly with what it really does. We also have
to change name rules in Makefile to be consistent.
@lunika lunika force-pushed the fix/keycloak-create-user branch from 08e45d8 to ee4402e Compare February 14, 2025 18:43
@lunika lunika merged commit 3191d89 into main Feb 14, 2025
17 of 19 checks passed
@lunika lunika deleted the fix/keycloak-create-user branch February 14, 2025 18:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants