Update docker and build to set API host
All checks were successful
release-image / release-image (push) Successful in 10m23s

This commit is contained in:
Logan Cusano
2025-05-26 19:36:38 -04:00
parent 009d3f7987
commit f16099ba38
2 changed files with 15 additions and 8 deletions

View File

@@ -20,24 +20,24 @@ jobs:
- name: Set up Docker BuildX
uses: docker/setup-buildx-action@v3
with: # replace it with your local IP
with:
config-inline: |
[registry."git.vpn.cusano.net"]
[registry."git.vpn.cusano.net"]
http = false
insecure = false
insecure = false
- name: Login to DockerHub
uses: docker/login-action@v3
with:
registry: git.vpn.cusano.net # replace it with your local IP
registry: git.vpn.cusano.net
username: ${{ secrets.GIT_REPO_USERNAME }}
password: ${{ secrets.GIT_REPO_PASSWORD }}
- name: Get Meta
id: meta
run: |
echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT
echo REPO_VERSION=$(git describe --tags --always | sed 's/^v//') >> $GITHUB_OUTPUT
echo REPO_VERSION=$(git describe --tags --always | sed 's/^v//') >> $GITHUB_OUTPUT
- name: Validate build configuration
uses: docker/build-push-action@v6
@@ -53,6 +53,8 @@ jobs:
linux/arm64
linux/amd64
push: true
tags: | # replace it with your local IP and tags
tags: |
git.vpn.cusano.net/logan/${{ env.CONTAINER_NAME }}:${{ steps.meta.outputs.REPO_VERSION }}
git.vpn.cusano.net/logan/${{ env.CONTAINER_NAME }}:${{ env.DOCKER_LATEST }}
git.vpn.cusano.net/logan/${{ env.CONTAINER_NAME }}:${{ env.DOCKER_LATEST }}
build-args: |
NEXT_PUBLIC_DRB_BASE_API_URL=${{ var.DRB_BASE_API_URL }}

View File

@@ -19,6 +19,11 @@ WORKDIR /app
COPY --from=deps /app/node_modules ./node_modules
COPY . .
# Add an ARG for NEXT_PUBLIC_DRB_BASE_API_URL
ARG NEXT_PUBLIC_DRB_BASE_API_URL
# Set it as an ENV variable for the build
ENV NEXT_PUBLIC_DRB_BASE_API_URL=${NEXT_PUBLIC_DRB_BASE_API_URL}
# Build the Next.js application for production
ENV NODE_ENV=production
RUN npm run build