You've already forked gun-manager
Compare commits
10 Commits
3dd63e2af1
...
v0.0.6
| Author | SHA1 | Date | |
|---|---|---|---|
|
c0fd8d6796
|
|||
|
a7fef89dda
|
|||
|
60e76f851e
|
|||
|
6e374e59f5
|
|||
|
fd1a88bd9f
|
|||
|
f0f8a399d7
|
|||
|
a01a16f1f1
|
|||
|
fac9dc0b92
|
|||
|
72325591b7
|
|||
|
fe8c090942
|
44
.gitea/workflows/build.yml
Normal file
44
.gitea/workflows/build.yml
Normal file
@@ -0,0 +1,44 @@
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
tag:
|
||||
description: 'Tag to build and push'
|
||||
required: false
|
||||
default: 'latest'
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
|
||||
name: 🏗️✨ Build Workflow
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
name: 🖥️ 🔨 Build
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: 📖 🔍 Checkout Repository Code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
submodules: 'true'
|
||||
|
||||
- name: 🔑 🔐 Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: scr.siteworxpro.com
|
||||
username: ${{ secrets.SITEWORX_USERNAME }}
|
||||
password: ${{ secrets.SITEWORX_PASSWORD }}
|
||||
|
||||
- name: 🏗️ 🔧 Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: 🐳 🔨 Build Container
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
push: true
|
||||
sbom: true
|
||||
provenance: true
|
||||
platforms: linux/arm64,linux/amd64
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
tags: scr.siteworxpro.com/gun-manager:${{ gitea.ref_name }}
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1 +1,2 @@
|
||||
.idea/
|
||||
data/
|
||||
@@ -1,5 +1,7 @@
|
||||
FROM node:22.14.0 AS frontend
|
||||
|
||||
ENV VITE_API=""
|
||||
|
||||
WORKDIR /frontend
|
||||
ADD frontend/ ./
|
||||
RUN npm install && npm run build
|
||||
@@ -21,6 +23,8 @@ WORKDIR /app
|
||||
COPY --from=frontend /frontend/dist /app/dist
|
||||
COPY --from=backend /backend/app /app/app
|
||||
|
||||
ADD backend/migrations /app/migrations
|
||||
|
||||
EXPOSE 8000
|
||||
|
||||
ENTRYPOINT ["/app/app"]
|
||||
6
README.md
Normal file
6
README.md
Normal file
@@ -0,0 +1,6 @@
|
||||
```shell
|
||||
docker run --rm \
|
||||
-v $(pwd)/data:/data \
|
||||
-p 8000:8000 \
|
||||
scr.siteworxpro.com/gun-manager:v0.0.3 -database /data/gun_inventory.sqlite
|
||||
```
|
||||
2
backend
2
backend
Submodule backend updated: 5ac3032a16...42bd95d804
36
docker-compose.yml
Normal file
36
docker-compose.yml
Normal file
@@ -0,0 +1,36 @@
|
||||
services:
|
||||
traefik:
|
||||
image: traefik:latest
|
||||
container_name: traefik
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
volumes:
|
||||
- "/var/run/docker.sock:/var/run/docker.sock"
|
||||
restart: always
|
||||
command:
|
||||
- "--providers.docker=true"
|
||||
- "--providers.docker.exposedByDefault=false"
|
||||
- "--entrypoints.web.address=:80"
|
||||
- "--entrypoints.web-secure.address=:443"
|
||||
- "--accesslog=true"
|
||||
- "--entrypoints.web.http.redirections.entryPoint.to=web-secure"
|
||||
- "--entrypoints.web.http.redirections.entryPoint.scheme=https"
|
||||
- "--entrypoints.web.http.redirections.entrypoint.permanent=true"
|
||||
|
||||
api:
|
||||
image: scr.siteworxpro.com/gun-manager:v0.0.6
|
||||
container_name: gun-manager
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.api.entrypoints=web-secure"
|
||||
- "traefik.http.routers.api.rule=Host(`localhost`) || Host(`127.0.0.1`)"
|
||||
- "traefik.http.routers.api.tls=true"
|
||||
- "traefik.http.services.api.loadbalancer.server.port=8000"
|
||||
volumes:
|
||||
- ./data:/app/data
|
||||
command:
|
||||
- "-database"
|
||||
- "./data/gun_inventory.sqlite"
|
||||
environment:
|
||||
CORS_ORIGINS: "https://localhost"
|
||||
2
frontend
2
frontend
Submodule frontend updated: c049df9a9f...7358bb1a4c
Reference in New Issue
Block a user