Skip to content

Commit 87ae370

Browse files
chore(ci): add env SOURCE_REPO_GIT, change runners for release ci to self-hosted (#942)
This PR introduces two key updates across multiple GitHub Actions workflows: Adds SOURCE_REPO_GIT environment variable (sourced from secrets) to workflows including dev_build_precache.yml, dev_module_build-and-registration.yml, and release_module_* configurations. Replaces ubuntu-latest runners with self-hosted large runners ([self-hosted, large]) for resource-intensive jobs like prod_ce_setup_build, prod_ee_setup_build, and downstream jobs in release workflows. --------- Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
1 parent 31b1dcb commit 87ae370

4 files changed

Lines changed: 14 additions & 37 deletions

File tree

.github/workflows/dev_build_precache.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ env:
2121
MODULES_REGISTRY_LOGIN: ${{ vars.DEV_MODULES_REGISTRY_LOGIN }}
2222
MODULES_REGISTRY_PASSWORD: ${{ secrets.DEV_MODULES_REGISTRY_PASSWORD }}
2323
SOURCE_REPO: "${{secrets.SOURCE_REPO}}"
24+
SOURCE_REPO_GIT: "${{secrets.SOURCE_REPO_GIT}}"
25+
2426
on:
2527
workflow_dispatch:
2628
schedule:

.github/workflows/dev_module_build-and-registration.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ env:
2424
RELEASE_CHANNEL: ${{ github.event.inputs.channel }}
2525
MODULES_MODULE_TAG: ${{ github.event.inputs.tag }}-dev
2626
SOURCE_REPO: "${{secrets.SOURCE_REPO}}"
27+
SOURCE_REPO_GIT: "${{secrets.SOURCE_REPO_GIT}}"
2728
GO_VERSION: "1.22.7"
2829
MODULE_EDITION: "EE"
2930

.github/workflows/release_module_build-and-registration.yml

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ env:
2323
MODULES_REGISTRY_PASSWORD: ${{ secrets.PROD_MODULES_REGISTRY_PASSWORD }}
2424
MODULES_MODULE_TAG: ${{ github.ref_name }}
2525
SOURCE_REPO: "${{ secrets.SOURCE_REPO }}"
26+
SOURCE_REPO_GIT: "${{secrets.SOURCE_REPO_GIT}}"
2627

2728
on:
2829
push:
@@ -39,7 +40,7 @@ concurrency:
3940

4041
jobs:
4142
prod_ce_setup_build:
42-
runs-on: ubuntu-latest
43+
runs-on: [self-hosted, large]
4344
name: Build and Push CE
4445
steps:
4546
- name: SET VAR
@@ -58,9 +59,6 @@ jobs:
5859
with:
5960
fetch-depth: 0
6061

61-
- name: Remove unwanted software
62-
uses: ./.github/actions/remove-unwanted-software
63-
6462
- name: Login to PROD_REGISTRY
6563
uses: deckhouse/modules-actions/setup@v2
6664
with:
@@ -82,7 +80,7 @@ jobs:
8280
secondary_repo: "${{ vars.DEV_MODULE_SOURCE }}/${{ vars.MODULE_NAME }}"
8381

8482
prod_ee_setup_build:
85-
runs-on: ubuntu-latest
83+
runs-on: [self-hosted, large]
8684
name: Build and Push EE
8785
steps:
8886
- name: SET VAR
@@ -101,9 +99,6 @@ jobs:
10199
with:
102100
fetch-depth: 0
103101

104-
- name: Remove unwanted software
105-
uses: ./.github/actions/remove-unwanted-software
106-
107102
- name: Login to PROD_REGISTRY
108103
uses: deckhouse/modules-actions/setup@v2
109104
with:
@@ -125,7 +120,7 @@ jobs:
125120
secondary_repo: "${{ vars.DEV_MODULE_SOURCE }}/${{ vars.MODULE_NAME }}"
126121

127122
prod_se_plus_setup_build:
128-
runs-on: ubuntu-latest
123+
runs-on: [self-hosted, large]
129124
needs: prod_ee_setup_build
130125
name: Build and Push SE Plus
131126
steps:
@@ -145,9 +140,6 @@ jobs:
145140
with:
146141
fetch-depth: 0
147142

148-
- name: Remove unwanted software
149-
uses: ./.github/actions/remove-unwanted-software
150-
151143
- name: Login to PROD_REGISTRY
152144
uses: deckhouse/modules-actions/setup@v2
153145
with:
@@ -169,7 +161,7 @@ jobs:
169161
secondary_repo: "${{ vars.DEV_MODULE_SOURCE }}/${{ vars.MODULE_NAME }}"
170162

171163
prod_fe_setup_build:
172-
runs-on: ubuntu-latest
164+
runs-on: [self-hosted, large]
173165
needs: prod_ee_setup_build
174166
name: Build and Push FE
175167
steps:
@@ -189,9 +181,6 @@ jobs:
189181
with:
190182
fetch-depth: 0
191183

192-
- name: Remove unwanted software
193-
uses: ./.github/actions/remove-unwanted-software
194-
195184
- name: Login to PROD_REGISTRY
196185
uses: deckhouse/modules-actions/setup@v2
197186
with:

.github/workflows/release_module_release-channels.yml

Lines changed: 6 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ env:
2424
MODULES_REGISTRY_PASSWORD: ${{ secrets.PROD_MODULES_REGISTRY_PASSWORD }}
2525
MODULES_MODULE_TAG: ${{ github.event.inputs.tag }}
2626
SOURCE_REPO: "${{secrets.SOURCE_REPO}}"
27+
SOURCE_REPO_GIT: "${{secrets.SOURCE_REPO_GIT}}"
2728

2829
on:
2930
workflow_dispatch:
@@ -58,7 +59,7 @@ on:
5859

5960
jobs:
6061
print-vars:
61-
runs-on: ubuntu-latest
62+
runs-on: [self-hosted, large]
6263
name: Print vars
6364
steps:
6465
- name: PRINT VARS
@@ -73,7 +74,7 @@ jobs:
7374

7475
job-CE:
7576
name: Edition CE
76-
runs-on: ubuntu-latest
77+
runs-on: [self-hosted, large]
7778
if: github.event.inputs.ce == 'true'
7879
steps:
7980
- run: echo "CE"
@@ -88,10 +89,6 @@ jobs:
8889
with:
8990
fetch-depth: 0
9091

91-
- name: Remove unwanted software
92-
if: ${{ github.event.inputs.enableBuild == 'true' }}
93-
uses: ./.github/actions/remove-unwanted-software
94-
9592
- name: Login to PROD_REGISTRY
9693
uses: deckhouse/modules-actions/setup@v2
9794
with:
@@ -122,7 +119,7 @@ jobs:
122119

123120
job-EE:
124121
name: Edition EE
125-
runs-on: ubuntu-latest
122+
runs-on: [self-hosted, large]
126123
if: github.event.inputs.ee == 'true'
127124
steps:
128125
- run: echo "EE"
@@ -137,10 +134,6 @@ jobs:
137134
with:
138135
fetch-depth: 0
139136

140-
- name: Remove unwanted software
141-
if: ${{ github.event.inputs.enableBuild == 'true' }}
142-
uses: ./.github/actions/remove-unwanted-software
143-
144137
- uses: deckhouse/modules-actions/setup@v2
145138
with:
146139
registry: ${{ vars.PROD_REGISTRY }}
@@ -178,7 +171,7 @@ jobs:
178171
job-SE-Plus:
179172
name: Edition SE Plus
180173
needs: job-EE
181-
runs-on: ubuntu-latest
174+
runs-on: [self-hosted, large]
182175
steps:
183176
- run: echo "SE Plus"
184177
- name: SET VAR
@@ -192,10 +185,6 @@ jobs:
192185
with:
193186
fetch-depth: 0
194187

195-
- name: Remove unwanted software
196-
if: ${{ github.event.inputs.enableBuild == 'true' }}
197-
uses: ./.github/actions/remove-unwanted-software
198-
199188
- name: Login to PROD_REGISTRY
200189
uses: deckhouse/modules-actions/setup@v2
201190
with:
@@ -227,7 +216,7 @@ jobs:
227216
job-FE:
228217
name: Edition FE
229218
needs: job-EE
230-
runs-on: ubuntu-latest
219+
runs-on: [self-hosted, large]
231220
steps:
232221
- run: echo "FE"
233222
- name: SET VAR
@@ -245,10 +234,6 @@ jobs:
245234
with:
246235
fetch-depth: 0
247236

248-
- name: Remove unwanted software
249-
if: ${{ github.event.inputs.enableBuild == 'true' }}
250-
uses: ./.github/actions/remove-unwanted-software
251-
252237
- name: Login to PROD_REGISTRY
253238
uses: deckhouse/modules-actions/setup@v2
254239
with:

0 commit comments

Comments
 (0)