webapp-deployment-status-api/Dockerfile

49 lines
1.9 KiB
Docker
Raw Normal View History

2024-02-03 01:39:21 +00:00
FROM ubuntu:22.04
RUN apt update && \
apt install -y --no-install-recommends --no-install-suggests \
2024-02-09 00:17:26 +00:00
netcat-traditional ca-certificates curl gnupg git fuse-overlayfs iproute2 podman iptables
2024-02-03 01:39:21 +00:00
# Node
ARG NODE_MAJOR=20
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \
apt update && apt install -y nodejs
# laconic-so
2024-02-06 22:35:58 +00:00
RUN curl -LO https://git.vdb.to/cerc-io/stack-orchestrator/releases/download/latest/laconic-so && \
2024-02-03 01:39:21 +00:00
chmod +x ./laconic-so && \
mv ./laconic-so /usr/bin/laconic-so
# laconic-registry-cli
RUN npm config set @cerc-io:registry https://git.vdb.to/api/packages/cerc-io/npm/ && \
2024-08-01 11:59:49 +00:00
npm install -g @cerc-io/laconic-registry-cli && \
2024-02-03 01:39:21 +00:00
npm install -g yarn
2024-02-24 01:27:52 +00:00
# docker-static (needed because of a bug with 'podman manifest').
ARG DOCKER_VER=25.0.3
WORKDIR /tmp
RUN curl -LO https://download.docker.com/linux/static/stable/x86_64/docker-${DOCKER_VER}.tgz && \
tar zxvf docker-${DOCKER_VER}.tgz docker/docker && \
mv docker/docker /usr/local/bin/docker-static && \
rm -rf docker-${DOCKER_VER}.tgz docker
2024-02-24 01:27:52 +00:00
# docker buildx plugin (needed for 'imagetools')
RUN mkdir -p /root/.docker/cli-plugins
ARG BUILDX_VER=0.12.1
RUN curl -LO https://github.com/docker/buildx/releases/download/v${BUILDX_VER}/buildx-v${BUILDX_VER}.linux-amd64 && \
mv buildx-v${BUILDX_VER}.linux-amd64 /root/.docker/cli-plugins/docker-buildx && \
chmod a+x /root/.docker/cli-plugins/docker-buildx
# Include our docker script.
COPY docker-wrapper.sh /usr/bin/docker
2024-02-03 01:39:21 +00:00
2024-02-09 00:17:26 +00:00
RUN mkdir -p /srv && mkdir -p /app
2024-02-03 01:39:21 +00:00
COPY . /app/
WORKDIR /app/
RUN rm -rf node_modules && yarn && yarn clean && yarn build:release
COPY scripts .
CMD ["./scripts/run.sh"]