Compare commits
9
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7898fdd516 | ||
|
|
8c9d228c99 | ||
|
|
35bed5a75d | ||
|
|
7b562cc17f | ||
|
|
3aa15039cb | ||
|
|
69422c2c72 | ||
|
|
159ee1b004 | ||
|
|
e7ac0e8af6 | ||
|
|
5278d65e50 |
@@ -1,3 +1,3 @@
|
|||||||
# App config Variables (Will be visible by client):
|
# App config Variables (Will be visible by client):
|
||||||
VITE_BACKEND_HOST=https://somniaapi.example.org/
|
VITE_BACKEND_HOST=${SOMNIA_BACKEND_HOST:-https://somniaapi.example.org/}
|
||||||
VITE_BACKEND_PORT=443
|
VITE_BACKEND_PORT=${SOMNIA_BACKEND_PORT:-443}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name: CI
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
pull_request: ~
|
||||||
|
workflow_dispatch: ~
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
lint:
|
||||||
|
name: Docker Lint
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Lint Dockerfile
|
||||||
|
uses: hadolint/[email protected]
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
name: Publish_on_Tag
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- devbuild_*
|
||||||
|
workflow_dispatch: ~
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
name: Build and Push
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v3
|
||||||
|
with:
|
||||||
|
platforms: arm64
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
|
- name: Log in to local registry
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
registry: ${{vars.REGISTRY_INSTANCE}}
|
||||||
|
username: ${{gitea.repository_owner}}
|
||||||
|
password: ${{secrets.REGISTRY_TOKEN}} # It should be a user/org token with package perms.
|
||||||
|
|
||||||
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v5
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
push: true
|
||||||
|
tags: ${{vars.REGISTRY_INSTANCE}}/daniel-garmig/somniaroomsapp:devbuild
|
||||||
|
target: final-prod
|
||||||
|
platforms: linux/amd64,linux/arm64
|
||||||
|
secrets: |
|
||||||
|
GIT_AUTH_TOKEN=${{secrets.REGISTRY_TOKEN}}
|
||||||
+1
-2
@@ -14,8 +14,7 @@ CMD ["npm", "run", "dev"]
|
|||||||
|
|
||||||
# Build app for production.
|
# Build app for production.
|
||||||
FROM app-base as builder
|
FROM app-base as builder
|
||||||
RUN npm ci
|
RUN npm ci && npm run build
|
||||||
RUN npm run build
|
|
||||||
|
|
||||||
# production environment
|
# production environment
|
||||||
FROM nginx:stable-alpine as final-prod
|
FROM nginx:stable-alpine as final-prod
|
||||||
|
|||||||
Reference in New Issue
Block a user