feat: Enable Git operations within a specified deployment directory by adding cwd options and configuring Git to trust the deploy directory.
This commit is contained in:
@@ -39,7 +39,8 @@ RUN apt-get update && apt-get install -y \
|
||||
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian bookworm stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y docker-ce-cli \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& git config --system --add safe.directory /app/deploy
|
||||
|
||||
# Copy only what's needed for production
|
||||
COPY --from=builder --chown=appuser:appgroup /app/node_modules ./node_modules
|
||||
|
||||
Reference in New Issue
Block a user