landing/.gitea/workflows/gitea.yaml
thomas 58a02ce74b
Some checks failed
Tomcode landing build/deploy / build (push) Failing after 0s
Update .gitea/workflows/gitea.yaml
2024-09-22 12:55:04 +02:00

39 lines
1.4 KiB
YAML

name: Tomcode landing build/deploy
run-name: Tomcode landing is being built and deployed 🚀
on: [push]
jobs:
build:
name: build
runs-on: node
steps:
- run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
- run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!"
- run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}."
- name: Check out repository code
uses: actions/checkout@v4
- name: Download dependencies
run: |
echo "Downloading dependencies."
npm ci --cache .npm --prefer-offline
- name: Build
run: |
echo "Building application."
npm run build --cache .npm --prefer-offline
- name: Dockerize
uses: docker://docker:stable-dind
env:
DOCKER_HOST: tcp://docker:2376
DOCKER_TLS_CERTDIR: "/certs"
DOCKER_TLS_VERIFY: 1
DOCKER_CERT_PATH: "$DOCKER_TLS_CERTDIR/client"
run: |
echo "Building docker image."
cd ./docker
docker build -t tomcode/landing:latest .
echo "Pushing docker image."
docker login git.tomcode.io -u thomas -p N0sflgdh@
docker push tomcode/landing:latest
- name: Testing host
uses: host
run: ls -la /