This commit is contained in:
Martin Cholewa 2025-01-20 15:12:13 +01:00
parent 2d2dc61238
commit 0b36e655d0
2 changed files with 36 additions and 0 deletions

34
workflows/ci.yml Normal file
View File

@ -0,0 +1,34 @@
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install dependencies
run: |
npm install
- name: Run tests
run: |
npm test
- name: Build Docker image
run: |
docker build -t my-app .
- name: Push Docker image to Gitea registry
run: |
echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
docker push my-app:latest

2
workflows/gitea-ci.yaml Normal file
View File

@ -0,0 +1,2 @@
name: Build And Test
run-name: ${{ gitea.actor }} is runs ci pipeline