-
Notifications
You must be signed in to change notification settings - Fork 1.3k
106 lines (97 loc) · 3.02 KB
/
workflow-pr.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: Pull Request Workflow
on:
pull_request:
branches:
- develop
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true
env:
JAVA_VERSION: "21"
DOCKER_APT_PACKAGES: python3 python3-venv python-is-python3 python3-pip nodejs npm curl zip unzip
DOCKER_PYTHON_LIBRARIES: kestra
PLUGIN_VERSION: ${{ github.event.inputs.plugin-version != null && github.event.inputs.plugin-version || 'LATEST' }}
# to save corepack from itself
COREPACK_INTEGRITY_KEYS: 0
jobs:
file-changes:
name: File changes detection
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: dorny/paths-filter@v3
id: changes
with:
filters: |
ui:
- 'ui/**'
translations:
- 'ui/src/translations/**'
backend:
- '!ui/**'
- '**'
- '!.github/**'
token: ${{ secrets.GITHUB_TOKEN }}
frontend:
name: 'Check Frontend'
needs: file-changes
runs-on: ubuntu-latest
timeout-minutes: 60
if: steps.file-changes.outputs.changes.ui == 'true'
steps:
- id: generate-translations
name: Generate translations
if: steps.file-changes.outputs.changes.translations == 'true'
uses: ./.github/actions/action-generate-translations
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
- id: frontend-test
name: Frontend test
uses: ./.github/actions/action-frontend-test
backend:
name: 'Check Backend'
needs: file-changes
runs-on: ubuntu-latest
timeout-minutes: 60
if: steps.file-changes.outputs.changes.backend == 'true'
steps:
- name: Backend test
uses: ./.github/actions/action-backend-test
build-artifacts:
if: steps.file-changes.outputs.changes.backend == 'true' || steps.file-changes.outputs.changes.ui == 'true'
name: Build artifacts
runs-on: ubuntu-latest
steps:
- uses: ./.github/actions/action-build-artifacts
id: build-artifacts
e2e:
name: Check E2E
needs: [build-artifacts]
uses: ./.github/workflows/e2e.yml
strategy:
fail-fast: false
matrix:
backends: [ "postgres" ]
with:
tags: oss
backend: ${{ matrix.backends }}
docker-artifact-name: ${{ needs.build-artifacts.outputs.docker-artifact-name }}
docker-image-tag: kestra/kestra:${{ needs.build-artifacts.outputs.docker-tag }}
secrets:
GITHUB_AUTH_TOKEN: ${{ secrets.GH_PERSONAL_TOKEN }}
GOOGLE_SERVICE_ACCOUNT: ${{ secrets.GOOGLE_SERVICE_ACCOUNT }}
end:
name: End
runs-on: ubuntu-latest
if: always()
steps:
# Slack
- name: Slack notification
uses: Gamesight/slack-workflow-status@master
if: ${{ always() && env.SLACK_WEBHOOK_URL != 0 }}
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
slack_webhook_url: ${{ secrets.SLACK_WEBHOOK_URL }}
name: GitHub Actions
icon_emoji: ":github-actions:"
channel: "C02DQ1A7JLR"