Обновить .gitea/workflows/test.yml
Some checks failed
Build and Test Application / build (push) Failing after 1m36s

This commit is contained in:
mt77 2025-04-11 20:56:44 +05:00
parent 294deea151
commit 5a67664739

View File

@ -1,9 +1,36 @@
name: Build and Test Application
on: [push]
env:
GIT_INSTANCE: git01prod.lan
jobs:
build:
runs-on: docker
steps:
# Шаг 1: Checkout кода
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
# Шаг 2: Установка Node.js
- name: Checkout repository
uses: actions/checkout@v3
# Шаг 4: Логин в Docker Registry (Gitea)
- name: Login to Gitea Container Registry
uses: docker/login-action@v3
with:
registry: $GIT_INSTANCE # Замените на адрес вашего Gitea
username: ${{ secrets.GIT_USERNAME }}
password: ${{ secrets.GIT_TOKEN }}
# Шаг 5: Сборка и пуш Docker образа
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: |
$GIT_INSTANCE/${{ secrets.GIT_USERNAME }}/monitor:latest
$GIT_INSTANCE/${{ secrets.GIT_USERNAME }}/monitor:${{ github.sha }}