Skip to content

Commit da8ccf6

Browse files
authored
Merge pull request #731 from MiraGeoscience/DEVOPS-820
DEVOPS-820: use shared github workflows in geoapps
2 parents 343202e + ff9a537 commit da8ccf6

4 files changed

Lines changed: 55 additions & 5 deletions

File tree

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,20 @@
11
name: Create JIRA issue
2+
permissions:
3+
contents: read
4+
issues: write
25

36
on:
47
issues:
58
types: [opened]
69

710
jobs:
811
call-workflow-create-jira-issue:
12+
if: startsWith(github.repository, 'MiraGeoscience/') # run on the Mira repo only
913
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-jira-issue_to_jira.yml@main
10-
secrets: inherit
14+
secrets:
15+
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }}
16+
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
17+
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}
1118
with:
1219
project-key: 'GEOPY'
1320
components: '[{"name": "geoapps"}]'
Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,20 @@
11
name: Add JIRA issue summary
22

33
on:
4-
pull_request_target:
5-
types: [opened, synchronize]
4+
pull_request:
5+
types: [opened]
6+
permissions:
7+
contents: read
8+
pull-requests: write
69

710
jobs:
811
call-workflow-add-jira-issue-summary:
12+
if: startsWith(github.event.pull_request.head.repo.full_name, 'MiraGeoscience/') # run if PR originates from the Mira repo only
913
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-jira-pr_add_jira_summary.yml@main
10-
secrets: inherit
14+
permissions:
15+
contents: read
16+
pull-requests: write
17+
secrets:
18+
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }}
19+
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
20+
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}

.github/workflows/python_analysis.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,21 +24,28 @@ concurrency:
2424
jobs:
2525
call-workflow-static-analysis:
2626
name: Static analysis
27+
permissions:
28+
contents: read
29+
pull-requests: read
2730
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-static_analysis.yml@main
2831
with:
2932
package-manager: 'conda'
3033
app-name: 'geoapps'
3134
python-version: '3.10'
35+
3236
call-workflow-pytest:
3337
name: Pytest
38+
permissions:
39+
contents: read
40+
pull-requests: read
3441
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-pytest.yml@main
3542
with:
3643
package-manager: 'conda'
3744
python-versions: '["3.10"]'
3845
os: '["ubuntu-latest", "windows-latest"]'
46+
lfs: true
3947
cache-number: 1
4048
codecov-reference-python-version: '3.10'
4149
codecov-reference-os: '["windows-latest"]'
42-
lfs: true
4350
secrets:
4451
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Zizmor analysis
2+
3+
on:
4+
pull_request:
5+
types: [opened, synchronize, reopened, ready_for_review]
6+
branches:
7+
- develop
8+
- main
9+
- release/**
10+
- feature/**
11+
- hotfix/**
12+
push:
13+
branches:
14+
- main
15+
- develop
16+
- feature/**
17+
- hotfix/**
18+
- release/**
19+
20+
jobs:
21+
call-workflow-zizmor:
22+
name: Zizmor analysis
23+
permissions:
24+
contents: read
25+
actions: read
26+
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-zizmor-security.yml@main

0 commit comments

Comments
 (0)