Readme on mount custom config is wrong
Name and Version
bitnami/mariadb:10
What steps will reproduce the bug?
Go to https://github.com/bitnami/containers/tree/main/bitnami/mariadb#configuration-file and read how to mount a custom config file.
create a custom conf file my_custom.cnf
[mysqld]
max_allowed_packet=32M
create a docker-compose.yaml file:
version: "3"
services:
mariadb:
image: docker.io/bitnami/mariadb:10
volumes:
- "mariadb_data:/bitnami/mariadb"
- ./my_custom.cnf:/opt/bitnami/mariadb/conf/my_custom.cnf:ro
environment:
- ALLOW_EMPTY_PASSWORD=no
- MARIADB_USER=dbuser
- MARIADB_PASSWORD=dbpass
- MARIADB_ROOT_PASSWORD=dbrootpass
- MARIADB_DATABASE=db
ports:
- 3306:3306
volumes:
mariadb_data:
driver: local
run docker compose up
What is the expected behavior?
Expected: I expect the configuration to get respected - or the documentation should be right on the mountable path.
chaning the path to /bitnami/mariadb/conf/my_custom.cnf:ro - which apparently gets symlinked to /bitnami/mariadb/conf/ fixes the issue for me.
- - ./my_custom.cnf:/opt/bitnami/mariadb/conf/my_custom.cnf:ro
+ - ./my_custom.cnf:/bitnami/mariadb/conf/my_custom.cnf:ro
What do you see instead?
test-mariadb-1 | Error executing 'postInstallation': EEXIST: file already exists, symlink '/bitnami/mariadb/conf' -> '/opt/bitnami/mariadb/conf'
Thanks for reporting this issue. Would you like to contribute by creating a PR to solve the issue? The Bitnami team will be happy to review it and provide feedback. Here you can find the contributing guidelines.
sure - could you please confirm quickly that the readme is wrong on this, and that /bitnami/mariadb/conf/ would be the correct path since it gets symlinked on container start?
I was able to reproduce the original issue and then check how the proposed solution works like a charm, so yes, I think this is a valid workaround!
This Issue has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thanks for the feedback.
Due to the lack of activity in the last 5 days since it was marked as "stale", we proceed to close this Issue. Do not hesitate to reopen it later if necessary.