papibot/Dockerfile.runtime
Xander Bazzi d6ebe0f0e5 Dockerize the build process
Add docker build commands to README

Clean up Dockerfile.runtime
2025-02-13 23:54:20 -05:00

17 lines
490 B
Docker

FROM www.gitgud.foo/thegrind/papibot-builder:latest as build
# Create a group and user 'papibot'
RUN groupadd -r papibot && useradd -r -g papibot papibot
# Switch to the 'papibot' user
USER papibot
# Copy the necessary files from the build stage
COPY --from=build --chown=papibot:papibot /usr/bin/ /usr/bin
COPY --from=build --chown=papibot:papibot /app/ /app/
# Set the working directory to /app
WORKDIR /app/
# Set the entry point to the built Go application
ENTRYPOINT ["./papibot"]