Skip to content
Open
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
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ web:
- APP_DB_NAME=openxpki
- APP_DB_USER=openxpki
- APP_DB_PASS=openxpki
- APP_DB_ROOT_PASS=my-super-secret-password
- APP_DB_ROOT_PASS=my-super-secret-password
10 changes: 8 additions & 2 deletions scripts/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,16 @@ function create_config {
echo "Found custom configuration, securing and executing it."
chown root:root /etc/openxpki/customconfig.sh
chmod 700 /etc/openxpki/customconfig.sh
/etc/openxpki/customconfig.sh
sh /etc/openxpki/customconfig.sh
elif [ -f "/usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh.gz" ]; then
echo "Found no custom customconfig.sh - using default compressed sampleconfig.sh.gz from /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh"
gunzip /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh.gz
Copy link
Contributor

Choose a reason for hiding this comment

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

I had to change this line to

gunzip < /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh.gz > /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh

Otherwise gunzip complained about hard links on this file (at least with overlay storage driver).

chown root:root /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh
chmod 700 /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh
sh /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh
elif [ -f "/usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh" ]; then
echo "Found no custom customconfig.sh - using default sampleconfig.sh from /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh"
/usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh
sh /usr/share/doc/libopenxpki-perl/examples/sampleconfig.sh
else
echo "Found no sampleconfig.sh and no customconfig.sh"
exit 1
Expand Down