forked from github.com/GenderDysphoria.fyi
Fix ci
This commit is contained in:
@@ -18,6 +18,16 @@ jobs:
|
|||||||
name: Get current date
|
name: Get current date
|
||||||
id: date
|
id: date
|
||||||
run: echo "::set-output name=date::$(date +'%Y%m%d%H%M%S')"
|
run: echo "::set-output name=date::$(date +'%Y%m%d%H%M%S')"
|
||||||
|
-
|
||||||
|
name: Set up docker buildx...
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
-
|
||||||
|
name: Login to gitea registry
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
registry: gitea.raer.me
|
||||||
|
username: ${{ secrets.PRODUCTION_REGISTRY_USERNAME }}
|
||||||
|
password: ${{ secrets.PRODUCTION_REGISTRY_TOKEN }}
|
||||||
-
|
-
|
||||||
name: Checkout the git repo...
|
name: Checkout the git repo...
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
@@ -50,29 +60,9 @@ jobs:
|
|||||||
-
|
-
|
||||||
name: Build site
|
name: Build site
|
||||||
run: npm run build
|
run: npm run build
|
||||||
# -
|
|
||||||
# name: Create artifact...
|
|
||||||
# run: 7z a -mx=9 ./artifact.7z dist
|
|
||||||
# -
|
|
||||||
# name: Upload artifact...
|
|
||||||
# uses: actions/upload-artifact@v3
|
|
||||||
# with:
|
|
||||||
# name: build_artifact
|
|
||||||
# path: dist
|
|
||||||
# retention-days: 7
|
|
||||||
-
|
-
|
||||||
name: Copy dist to docker...
|
name: Copy dist to docker...
|
||||||
run: cp -a dist docker/
|
run: npm cache clean;cp -a dist docker/
|
||||||
-
|
|
||||||
name: Set up docker buildx...
|
|
||||||
uses: docker/setup-buildx-action@v3
|
|
||||||
-
|
|
||||||
name: Login to gitea registry
|
|
||||||
uses: docker/login-action@v3
|
|
||||||
with:
|
|
||||||
registry: gitea.raer.me
|
|
||||||
username: ${{ secrets.PRODUCTION_REGISTRY_USERNAME }}
|
|
||||||
password: ${{ secrets.PRODUCTION_REGISTRY_TOKEN }}
|
|
||||||
-
|
-
|
||||||
name: Build and push docker image to gitea package store
|
name: Build and push docker image to gitea package store
|
||||||
uses: docker/build-push-action@v5
|
uses: docker/build-push-action@v5
|
||||||
@@ -81,6 +71,16 @@ jobs:
|
|||||||
push: true
|
push: true
|
||||||
platforms: linux/amd64
|
platforms: linux/amd64
|
||||||
tags: gitea.raer.me/${{ gitea.repository }}:${{ gitea.ref_name }}
|
tags: gitea.raer.me/${{ gitea.repository }}:${{ gitea.ref_name }}
|
||||||
|
-
|
||||||
|
name: Create artifact...
|
||||||
|
run: 7z a -mx=9 artifact.7z dist
|
||||||
|
-
|
||||||
|
name: Upload artifact...
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: build_artifact
|
||||||
|
path: artifact.7z
|
||||||
|
retention-days: 7
|
||||||
# job2:
|
# job2:
|
||||||
# needs: job1
|
# needs: job1
|
||||||
# name: Build new docker container with new site build...
|
# name: Build new docker container with new site build...
|
||||||
|
|||||||
Reference in New Issue
Block a user