Fix CI
All checks were successful
Build and Publish Docker Image / build_and_push (push) Successful in 48s
All checks were successful
Build and Publish Docker Image / build_and_push (push) Successful in 48s
This commit is contained in:
@@ -52,8 +52,6 @@ jobs:
|
|||||||
uses: docker/build-push-action@v6
|
uses: docker/build-push-action@v6
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
build-args: |
|
|
||||||
NPM_TOKEN=${{ secrets.NPM_TOKEN }}
|
|
||||||
file: ./Dockerfile
|
file: ./Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: ${{ steps.set_tags.outputs.image_tags }}
|
tags: ${{ steps.set_tags.outputs.image_tags }}
|
||||||
|
|||||||
3
.npmrc
3
.npmrc
@@ -1,2 +1 @@
|
|||||||
@3t.network:registry=https://git.3t.network/api/packages/3t.network/npm/
|
@3t.network:registry=https://git.3t.network/api/packages/3t.network/npm/
|
||||||
//git.3t.network/api/packages/3t.network/npm/:_authToken=${NPM_TOKEN}
|
|
||||||
@@ -16,8 +16,7 @@ FROM base AS build
|
|||||||
COPY package*.json tsconfig.json .npmrc ./
|
COPY package*.json tsconfig.json .npmrc ./
|
||||||
|
|
||||||
# Install
|
# Install
|
||||||
ARG NPM_TOKEN
|
RUN npm install
|
||||||
RUN npm install --//npm.token=${NPM_TOKEN}
|
|
||||||
|
|
||||||
# Copy the app
|
# Copy the app
|
||||||
COPY src ./src
|
COPY src ./src
|
||||||
@@ -30,8 +29,7 @@ FROM node:lts-alpine
|
|||||||
|
|
||||||
# Install dependencies but skip dev dependencies
|
# Install dependencies but skip dev dependencies
|
||||||
COPY --from=build /app/package*.json /app/.npmrc ./
|
COPY --from=build /app/package*.json /app/.npmrc ./
|
||||||
ARG NPM_TOKEN
|
RUN npm install --only=production
|
||||||
RUN npm install --only=production --//npm.token=${NPM_TOKEN}
|
|
||||||
|
|
||||||
# Copy the app
|
# Copy the app
|
||||||
COPY --from=build /app/dist ./dist
|
COPY --from=build /app/dist ./dist
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ fi
|
|||||||
# cd to the project root directory.
|
# cd to the project root directory.
|
||||||
cd "$(dirname "$0")/.."
|
cd "$(dirname "$0")/.."
|
||||||
source .env
|
source .env
|
||||||
docker build --build-arg NPM_TOKEN=$NPM_TOKEN -t butlerbot:$VERSION .
|
docker build -t butlerbot:$VERSION .
|
||||||
|
|
||||||
# Tag the Docker image.
|
# Tag the Docker image.
|
||||||
for TAG in "${TAGS[@]}"; do
|
for TAG in "${TAGS[@]}"; do
|
||||||
|
|||||||
Reference in New Issue
Block a user