Compare commits

...

2 Commits

Author SHA1 Message Date
3fd0398a78 Feat: add build workflow
All checks were successful
Build and push image / release-image (push) Successful in 3m9s
2025-07-10 15:22:21 +08:00
41edac16c4 Feat: add Dockerfile 2025-07-10 15:22:01 +08:00
2 changed files with 35 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
name: Build and push image
on: [push]
jobs:
release-image:
runs-on: imgbuilder
steps:
- name: Build and push image
uses: https://gitea.konchin.com/action/docker@main
with:
registry-certificate: ${{ vars.ROOTCA }}
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}

22
Dockerfile Normal file
View File

@@ -0,0 +1,22 @@
FROM gitea.konchin.com/image/alpine:latest
# Set the working directory inside the container
WORKDIR /usr/src/app
# Copy package.json and package-lock.json to the working directory
COPY package*.json ./
# Install the application dependencies
RUN npm install
# Copy the rest of the application files
COPY . .
# Build the NestJS application
RUN npm run build
# Expose the application port
EXPOSE 3000
# Command to run the application
CMD ["node", "dist/main"]