Compare commits

...

3 commits

Author SHA1 Message Date
fc5f8b2f11 Removing github workflow
All checks were successful
ci/woodpecker/push/test Pipeline was successful
2025-02-02 14:02:59 +01:00
d5ccc4e570 Updating image of woodpecker test to node/hydrogen
Some checks failed
ci/woodpecker/push/test Pipeline was successful
Push to main / test (push) Has been cancelled
Push to main / build-image (push) Has been cancelled
2025-02-02 12:18:16 +01:00
3e0ba829d3
Adding woodpecker-cicd workflow file
Some checks failed
Push to main / test (push) Waiting to run
Push to main / build-image (push) Blocked by required conditions
ci/woodpecker/push/test Pipeline failed
Signed-off-by: Collin Duncan <github@collinduncan.com>
2025-02-02 11:25:02 +01:00
2 changed files with 10 additions and 43 deletions

View file

@ -1,43 +0,0 @@
name: Push to main
on:
push:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/hydrogen
- run: npm ci
- run: npm run test:unit
build-image:
needs:
- test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.GHCR_USERNAME }}
password: ${{ secrets.GHCR_PASSWORD }}
- name: Declare GIT_COMMIT
shell: bash
run: |
echo "GIT_COMMIT=$(git rev-parse --short "$GITHUB_SHA")" >> "$GITHUB_ENV"
- name: Build docker image
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/server/Dockerfile
push: true
tags: ghcr.io/cgduncan7/autobaan:latest
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: GIT_COMMIT=${{ env.GIT_COMMIT }}

10
.woodpecker/test.yaml Normal file
View file

@ -0,0 +1,10 @@
when:
- branch: main
event: push
steps:
- name: test
image: docker.io/node:hydrogen-slim
commands:
- npm ci
- npm run test:unit