11 Commits

Author SHA1 Message Date
a485f333a4 Delete gitea.json 2025-11-25 13:36:09 +03:00
90ebee91ae Update dispatch action 2025-11-25 11:38:37 +03:00
e42e641898 Update dispatch action 2025-11-25 11:35:55 +03:00
b0245c89da Update dispatch action 2025-11-25 11:29:54 +03:00
76841ae85a Add dispatch action 2025-11-25 11:27:14 +03:00
9ff4134367 Update condition 2025-11-25 10:29:07 +03:00
c810bb889a Update condition 2025-11-25 10:28:18 +03:00
7cca6f856d Update condition 2025-11-25 10:25:47 +03:00
65c8b55f54 Add condition example 2025-11-25 10:19:33 +03:00
a8cbb476ba Update action 2025-11-25 09:27:13 +03:00
cee776d263 Update action 2025-11-25 09:25:37 +03:00
3 changed files with 54 additions and 1 deletions

View File

@@ -3,18 +3,31 @@ run-name: "Start example action"
on: on:
push: push:
tags:
- v*.*.*
jobs: jobs:
second-job: second-job:
runs-on: docker # docker, sirius или golang runs-on: docker # docker, sirius или golang
steps: steps:
- run: |
if [ ${{ gitea.actor }} == 'alex' ]; then
echo "Hello, ${{ gitea.actor }}"
else
echo "Hello, student"
fi
# Клонируем репозиторий для Runnera # Клонируем репозиторий для Runnera
- name: Checkout rpository - name: Checkout rpository
uses: actions/checkout@v6 uses: actions/checkout@v6
# Выводим текстовое сообщение # Выводим текстовое сообщение
- name: Echo test - name: Echo test
run: echo "Hello!" run: echo "Hello, ${{ gitea.actor }}"
# Выводим путь к репозиторию
- name: Repo name
run: echo "Hello, ${{ gitea.repository }}"
# Выводим переменные окружения # Выводим переменные окружения
- name: Show environment - name: Show environment
@@ -23,3 +36,7 @@ jobs:
# Выводим контекст Gitea в формате JSON # Выводим контекст Gitea в формате JSON
- name: Show Gitea context - name: Show Gitea context
run: echo "${{ toJson(gitea) }}" run: echo "${{ toJson(gitea) }}"
# Выводим контекст Gihub в формате JSON
- name: Show Gitea context
run: echo "${{ toJson(github) }}"

View File

@@ -0,0 +1,17 @@
name: "Example condition"
run-name: "Check Job condition"
on:
issues:
types:
- labeled
jobs:
check-condition:
runs-on: sirius # docker, sirius или golang
if: contains(github.event.issue.labels.*.name, 'bug')
steps:
# Выводим текстовое сообщение
- name: Echo test
run: echo "${{ toJson(gitea.event.issue) }}"

View File

@@ -0,0 +1,19 @@
name: "Example dispatch"
on:
workflow_dispatch:
jobs:
echo-test:
runs-on: docker # docker, sirius или golang
steps:
# Выводим текстовое сообщение
- name: Echo test
run: echo "Hello!"
- name: Install kubectl action
uses: tale/kubectl-action@v1
with:
base64-kube-config: ${{ secrets.KUBE_CONFIG }}
- run: kubectl get pods