Skip to content
Snippets Groups Projects
Commit 12963eb9 authored by Hugo Trentesaux's avatar Hugo Trentesaux
Browse files

add docker build script

parent 82ad4810
No related branches found
No related tags found
No related merge requests found
......@@ -7,7 +7,7 @@ COPY ./package.json ./pnpm-lock.yaml /app/
WORKDIR /app
# build deps
FROM base as deps
FROM base AS deps
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --frozen-lockfile
# datapod image
......
#!/bin/bash
set -e
# Get the version number from package.json
version_tag=$(grep -oP '"version": "\K[^"]+' package.json)
# --- datapod
docker buildx build -f Dockerfile -t duniter-datapod .
# Tag with version and 'latest'
docker image tag duniter-datapod h30x/duniter-datapod:$version_tag
docker image tag duniter-datapod h30x/duniter-datapod:latest
# Push both
docker image push h30x/duniter-datapod:$version_tag
docker image push h30x/duniter-datapod:latest
# --- kubo
docker buildx build -f Dockerfile.Kubo -t datapod-kubo .
# Tag with version and 'latest'
docker image tag datapod-kubo h30x/datapod-kubo:$version_tag
docker image tag datapod-kubo h30x/datapod-kubo:latest
# Push both
docker image push h30x/datapod-kubo:$version_tag
docker image push h30x/datapod-kubo:latest
# --- hasura
docker buildx build -f Dockerfile.Hasura -t datapod-hasura .
# Tag with version and 'latest'
docker image tag datapod-hasura h30x/datapod-hasura:$version_tag
docker image tag datapod-hasura h30x/datapod-hasura:latest
# Push both
docker image push h30x/datapod-hasura:$version_tag
docker image push h30x/datapod-hasura:latest
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment