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

Fix kong permission and execution errors in wrapper.sh #45

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

pieveee
Copy link
Contributor

@pieveee pieveee commented May 8, 2023

What kind of change does this PR introduce?

Bug fix

What is the current behavior?

Currently, kong fails to start running with the following error:

/scripts/wrapper.sh: 3: set: Illegal option -o pipefail

And:

/scripts/wrapper.sh: line 8: /home/kong/kong.yml: Permission denied

What is the new behavior?

  1. The shebang was adjusted from /bin/sh to /bin/bash (See https://www.baeldung.com/linux/illegal-option-o-pipefail)
  2. kong.yml declarative configuration file was moved from /home/kong/kong.yml to /usr/local/kong/kong.yml, as well as /home/kong/template.yml to /usr/local/template.yml in order to run wrapper.sh script without permission issues

pieveee added 9 commits May 7, 2023 18:50
If the database provided is being disabled in values.yaml (e.g. because of using a replicated database solution) the helm installation would fail with: 
Error: INSTALLATION FAILED: template: supabase/templates/db/storage.yaml:1:14: executing "supabase/templates/db/storage.yaml" at <.Values.db.persistence.enabled>: nil pointer evaluating interface {}.enabled
Fix missing if-clause when database is disabled
Currently, the container for kong would not start as wrapper.sh fails in its execution with "Illegal option -o pipefail"  (See: https://www.baeldung.com/linux/illegal-option-o-pipefail#how-to-avoid-the-error).
The /home/kong/ directory doesn't exist in the newest Docker image of kong. Hence, the kong.yml should be stored at an existing and writeable directory.
Change wrapper.sh execution from sh to bash
@pieveee
Copy link
Contributor Author

pieveee commented Jul 7, 2023

@milanvanschaik Can you check the merge request?

@ngladbach
Copy link

@milanvanschaik @bigbitbus @icrotz @cpdeethree @devudopw @kiwicopple could you have a look?

@icrotz
Copy link
Contributor

icrotz commented Sep 21, 2023

I don't have the rights to merge on this repository

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants