main
Some checks failed
Deploy Frontend / build-and-deploy (push) Failing after 19h27m44s

This commit is contained in:
2026-02-07 01:52:31 +03:00
parent 73c2a2a2e7
commit a8236e8783
30 changed files with 94 additions and 168 deletions

45
.github/workflows/deploy-ui.yml vendored Normal file
View File

@@ -0,0 +1,45 @@
name: Deploy Frontend
run-name: ${{ gitea.actor }} is deploying frontend 🚀
on:
push:
branches:
- main
- master
jobs:
build-and-deploy:
runs-on: ubuntu-latest
container:
image: catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Build and Push Docker Image
run: |
docker build \
--build-arg NEXT_PUBLIC_API_URL='${{ secrets.NEXT_PUBLIC_API_URL }}' \
--build-arg NEXT_PUBLIC_AUTH_REQUIRED='false' \
-t skript-ui .
- name: Stop and Remove Existing Container
run: |
docker stop ui-skript-container || true
docker rm ui-skript-container || true
- name: Run New Container
run: |
docker run -d \
--name ui-skript-container \
--restart unless-stopped \
--network gitea-server_gitea \
-p 1506:3000 \
-e NEXTAUTH_URL='${{ secrets.NEXTAUTH_URL }}' \
-e NEXTAUTH_SECRET='${{ secrets.NEXTAUTH_SECRET }}' \
-e INTERNAL_API_URL='http://backend-skript-container:3000' \
skript-ui
- name: Cleanup
run: docker image prune -f