This commit is contained in:
parent
e53c007293
commit
7944db21f2
40
.gitea/workflows/deploy.yml
Normal file
40
.gitea/workflows/deploy.yml
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
name: Deploy
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Keyscan
|
||||||
|
run: |
|
||||||
|
ssh-keyscan git.koptilnya.xyz >> ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }}
|
||||||
|
ssh-strict: false
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: docker build -t bpmn:latest .
|
||||||
|
|
||||||
|
- name: Stop old container
|
||||||
|
run: docker rm -f bpmn || true
|
||||||
|
|
||||||
|
- name: Run
|
||||||
|
run: |
|
||||||
|
docker run -d \
|
||||||
|
--name bpmn \
|
||||||
|
--network traefik \
|
||||||
|
--label "traefik.enable=true" \
|
||||||
|
--label "traefik.http.routers.bpmn.rule=Host(\`bpmn.koptilnya.xyz\`)" \
|
||||||
|
--label "traefik.http.routers.bpmn.entrypoints=websecure" \
|
||||||
|
--label "traefik.http.routers.bpmn.tls.certresolver=myresolver" \
|
||||||
|
--label "traefik.http.services.bpmn.loadbalancer.server.port=80" \
|
||||||
|
bpmn:latest
|
||||||
15
Dockerfile
Normal file
15
Dockerfile
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
FROM node:22-alpine AS build
|
||||||
|
WORKDIR /app
|
||||||
|
RUN corepack enable
|
||||||
|
COPY package.json yarn.lock ./
|
||||||
|
RUN yarn install
|
||||||
|
COPY . .
|
||||||
|
RUN yarn build
|
||||||
|
|
||||||
|
FROM nginx:stable-alpine
|
||||||
|
|
||||||
|
COPY --from=build /app/dist /usr/share/nginx/html
|
||||||
|
|
||||||
|
EXPOSE 80
|
||||||
|
|
||||||
|
CMD ["nginx", "-g", "daemon off;"]
|
||||||
@ -186,7 +186,7 @@ export function useCollaborativeFlow(diagramId: MaybeRefOrGetter<string>) {
|
|||||||
return
|
return
|
||||||
|
|
||||||
provider.value = new WebsocketProvider(
|
provider.value = new WebsocketProvider(
|
||||||
'ws://localhost:1234',
|
import.meta.env.DEV ? 'ws://localhost:1234' : 'wss://api/koptilnya.xyz/bpmn',
|
||||||
diagramId,
|
diagramId,
|
||||||
yDoc,
|
yDoc,
|
||||||
)
|
)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user