tech: ajout repo avec build main
Signed-off-by: Gato <cedric@goutailler-olivier.fr>
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM node:22-alpine AS builder
|
||||
RUN apk add --no-cache git openssh
|
||||
RUN mkdir -p /root/.ssh && \
|
||||
ssh-keyscan -p 2222 git.goutailler-olivier.com >> /root/.ssh/known_hosts
|
||||
RUN --mount=type=ssh \
|
||||
--mount=type=cache,target=/root/.npm \
|
||||
git clone --depth 1 --branch main \
|
||||
ssh://git@git.goutailler-olivier.com:2222/Gato/Bonsai-webapp.git /src && \
|
||||
cd /src && npm ci --cache /root/.npm && npm run build
|
||||
|
||||
FROM nginx:alpine
|
||||
COPY --from=builder /src/dist/Bonsai-webapp/browser /usr/share/nginx/html
|
||||
COPY --from=builder /src/nginx.conf /etc/nginx/conf.d/default.conf
|
||||
EXPOSE 80
|
||||
Reference in New Issue
Block a user