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 PG_DATADIR initialization for cases when empty or contains too many files #152

Merged
merged 1 commit into from
Jun 28, 2023

Conversation

kkimurak
Copy link
Contributor

Previous implementation passed nothing to chmod when PG_DATADIR is empty. This results in chmod raises syntax error and wrong permissions will not be corrected : This is the cause of problem reported in sameersbn/docker-gitlab#2224
We also can see Argument list too long error when PG_DATADIR contains too many files / directories (restriction defined by ARG_MAX) : this is reported in #148

This PR make create_datadir() to handle those situations by using xargs.

Previous implementation passed nothing to `chmod` when
PG_DATADIR is empty - this results in `chmod` raises syntax error.
We also can see `Argument list too long` error when
PG_DATADIR contains too many files / directries
(restriction defined by ARG_MAX)

Use xargs to avoid errors above
@kkimurak
Copy link
Contributor Author

Rebased onto 0c081e0 (14-20230628 release).

@sameersbn sameersbn merged commit 6f65c43 into sameersbn:master Jun 28, 2023
1 check passed
@kkimurak kkimurak deleted the hotfix-chmod-failue branch June 28, 2023 09:43
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

2 participants