Files
Mikescher b36c2215c0
Build Docker and Deploy / Build Docker Container (push) Successful in 3m33s
Build Docker and Deploy / Run Unit-Tests (push) Successful in 6m43s
Build Docker and Deploy / Deploy to Server (push) Successful in 7s
[AUTO] Adjust gitea workflow for private goext dependency
2026-08-09 13:30:12 +02:00

47 lines
1.2 KiB
Docker

FROM golang:1-bullseye AS builder
RUN apt-get update && \
apt-get install -y ca-certificates openssl make git tar coreutils && \
apt-get install -y python3 python3-pip && \
pip install virtualenv && \
rm -rf /var/lib/apt/lists/*
# setup for private deps
RUN apt-get update && apt-get install -y --no-install-recommends git openssh-client && rm -rf /var/lib/apt/lists/*
COPY .secrets/deps-key /root/.ssh/id_ed25519
COPY .secrets/deps-key.pub /root/.ssh/id_ed25519.pub
RUN chmod 600 /root/.ssh/id_ed25519
COPY .secrets/known_hosts /root/.ssh/known_hosts
COPY .secrets/gitconfig /root/.gitconfig
ENV GOPRIVATE="git.blackforestbytes.com/*"
COPY . /buildsrc
RUN cd /buildsrc && cp "scn_send.sh" "../scn_send.sh" && make build
FROM debian:bookworm
RUN apt-get update && \
apt-get install -y --no-install-recommends ca-certificates && \
apt-get install -y --no-install-recommends tzdata && \
rm -rf /var/cache/apt/archives && \
rm -rf /var/lib/apt/lists
COPY --from=builder /buildsrc/_build/scn_backend /app/server
COPY --from=builder /buildsrc/DOCKER_GIT_INFO /DOCKER_GIT_INFO
RUN mkdir /data
WORKDIR /app
EXPOSE 80
CMD ["/app/server"]