Test docker image, basic functionality

This commit is contained in:
2026-07-29 20:05:17 +05:00
parent ec3af18549
commit 5b0bb25177
3 changed files with 108 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
#!/bin/bash
set -e
# Check if we are running as root (default)
if [ "$(id -u)" = "0" ]; then
# If /data is a directory, change its ownership to the container user
if [ -d "/data" ]; then
echo "Setting ownership of /data to appuser:appgroup"
chown -R appuser:appgroup /data
fi
# Drop privileges and run the command using gosu
exec gosu appuser "$@"
else
# If not root, just run the command directly
exec "$@"
fi