2023-04-02 17:41:30 +02:00
|
|
|
name: Build and Deploy
|
|
|
|
on: [push]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
Build:
|
2023-04-03 10:04:30 +02:00
|
|
|
runs-on: ubuntu-latest
|
2023-04-02 17:41:30 +02:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- name: Use Nodejs
|
|
|
|
uses: actions/setup-node@v3
|
|
|
|
with:
|
|
|
|
node-version: 18
|
|
|
|
- run: npm install
|
|
|
|
- run: npm run build
|
2023-04-03 10:17:54 +02:00
|
|
|
|
2023-04-02 17:41:30 +02:00
|
|
|
|
|
|
|
Deploy:
|
2023-04-28 10:48:44 +02:00
|
|
|
runs-on: ubuntu-latest
|
2023-04-02 17:41:30 +02:00
|
|
|
|
2023-04-28 10:45:56 +02:00
|
|
|
container:
|
|
|
|
image: catthehacker/ubuntu:act-latest
|
|
|
|
|
2023-04-02 17:41:30 +02:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
2023-04-03 10:17:54 +02:00
|
|
|
- name: Use Nodejs
|
|
|
|
uses: actions/setup-node@v3
|
2023-04-03 10:13:27 +02:00
|
|
|
with:
|
2023-04-03 10:17:54 +02:00
|
|
|
node-version: 18
|
|
|
|
- run: npm install
|
|
|
|
- run: npm run build
|
|
|
|
|
2023-04-03 09:29:37 +02:00
|
|
|
- uses: docker/setup-qemu-action@v2
|
|
|
|
- uses: docker/setup-buildx-action@v2
|
2023-04-28 11:32:28 +02:00
|
|
|
with:
|
|
|
|
driver-opts: |
|
|
|
|
image=moby/buildkit:latest
|
|
|
|
network=host
|
2023-04-11 10:15:59 +02:00
|
|
|
|
2023-04-02 17:41:30 +02:00
|
|
|
- uses: docker/login-action@v2
|
|
|
|
with:
|
|
|
|
registry: gitea.xeovalyte.dev
|
2023-04-02 17:43:36 +02:00
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
password: ${{ secrets.PASSWORD }}
|
2023-04-28 10:45:56 +02:00
|
|
|
|
2023-04-30 11:55:43 +02:00
|
|
|
- run: docker buildx build -t gitea.xeovalyte.dev/xeovalyte/portfolio --platform=linux/arm64 .
|
|
|
|
- run: docker push gitea.xeovalyte.dev/xeovalyte/portfolio
|