Skip to content
Merged
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
1 change: 0 additions & 1 deletion .docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ COPY .docker/entrypoint.sh /usr/local/bin/entrypoint
RUN python3 -m pip install --break-system-packages /greenbone-feed-sync/*

RUN chown -R gvm:gvm /greenbone-feed-sync && \
chown -R gvm:gvm /var/lib/ && \
chmod 755 /usr/local/bin/entrypoint

ENTRYPOINT [ "/usr/local/bin/entrypoint" ]
Expand Down
11 changes: 11 additions & 0 deletions .docker/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
#!/bin/bash

# Ensure the directories for lock files exist and are owned by gvm.
# This part runs as root (the default user before gosu) to ensure permissions are set correctly.
mkdir -p /var/lib/openvas
chown gvm:gvm /var/lib/openvas
chmod 775 /var/lib/openvas # Give group write access as well, for broader compatibility

mkdir -p /var/lib/gvm
chown gvm:gvm /var/lib/gvm
chmod 775 /var/lib/gvm # Give group write access as well, for broader compatibility

# Now execute the main command passed to the container as the gvm user.
exec gosu gvm "$@"
Loading