Skip to content

Commit 7427b7a

Browse files
Merge pull request #334 from 4dn-dcic/fm/dcic-oidc-9x
Migrate CI AWS auth to OIDC
2 parents 93a7203 + ec84960 commit 7427b7a

6 files changed

Lines changed: 24 additions & 9 deletions

File tree

.github/workflows/main.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ on:
1313
# Allows you to run this workflow manually from the Actions tab
1414
workflow_dispatch:
1515

16+
permissions:
17+
id-token: write
18+
contents: read
19+
1620
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
1721
jobs:
1822
# This workflow contains a single job called "build"
@@ -23,7 +27,7 @@ jobs:
2327
runs-on: ubuntu-22.04
2428
strategy:
2529
matrix:
26-
python_version: [3.9, 3.11, 3.12]
30+
python_version: [3.11, 3.12]
2731

2832
# Steps represent a sequence of tasks that will be executed as part of the job
2933
steps:
@@ -42,10 +46,14 @@ jobs:
4246
# show loaded versions of various poetry-related libraries
4347
pip freeze --all | egrep '(pip|poetry(.[a-z]+)?|tomlkit)=='
4448
49+
- name: Configure AWS Credentials
50+
uses: aws-actions/configure-aws-credentials@v4
51+
with:
52+
role-to-assume: ${{ secrets.AWS_OIDC_ROLE_ARN }}
53+
aws-region: us-east-1
54+
4555
- name: QA
4656
env:
47-
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
48-
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
4957
S3_ENCRYPT_KEY: ${{ secrets.S3_ENCRYPT_KEY }}
5058
GLOBAL_ENV_BUCKET: foursight-envs
5159
run: |
@@ -54,7 +62,7 @@ jobs:
5462
- name: Coveralls
5563
env:
5664
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
57-
if: ${{ matrix.python_version == '3.9' }}
65+
if: ${{ matrix.python_version == '3.11' }}
5866
run: |
5967
pip install coveralls
6068
poetry run coveralls --service=github

.github/workflows/static-checks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
build:
2020
name: Static checks of source code (PEP8 and our custom checks)
2121
# The type of runner that the job will run on
22-
runs-on: ubuntu-20.04
22+
runs-on: ubuntu-22.04
2323

2424
# Steps represent a sequence of tasks that will be executed as part of the job
2525
steps:

CHANGELOG.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ dcicutils
66
Change Log
77
----------
88

9+
8.18.5
10+
======
11+
* willronchetti / 2026-07-08 / branch: fm/dcic-oidc-9x
12+
- Migrated GitHub Actions AWS authentication for CI tests from long-lived access key secrets
13+
to OIDC via aws-actions/configure-aws-credentials and AWS_OIDC_ROLE_ARN.
14+
15+
916
8.18.4
1017
======
1118
* ajs / 2025-09-30 / branch: ajs_upd_es_metadata_fxns_250925 / PR-330

LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License
22

3-
Copyright 2017-2025 President and Fellows of Harvard College
3+
Copyright 2017-2026 President and Fellows of Harvard College
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "dcicutils"
3-
version = "8.18.4"
3+
version = "8.18.5"
44
description = "Utility package for interacting with the 4DN Data Portal and other 4DN resources"
55
authors = ["4DN-DCIC Team <support@4dnucleome.org>"]
66
license = "MIT"

test/test_license_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -759,13 +759,13 @@ def mocked_license_logger(message):
759759

760760
# Test that with no analysis argument, problems get sent out as warnings
761761
LicenseFileParser.validate_simple_license_file(filename='LICENSE.txt')
762-
assert license_warnings == ["The copyright year, '2020', should have '2025' at the end."]
762+
assert license_warnings == ["The copyright year, '2020', should have '2026' at the end."]
763763

764764
# Test that with an analysis argument, problems get summarized to that object
765765
analysis = LicenseAnalysis()
766766
license_warnings = []
767767
LicenseFileParser.validate_simple_license_file(filename='LICENSE.txt', analysis=analysis)
768-
assert analysis.miscellaneous == ["The copyright year, '2020', should have '2025' at the end."]
768+
assert analysis.miscellaneous == ["The copyright year, '2020', should have '2026' at the end."]
769769
assert license_warnings == []
770770

771771

0 commit comments

Comments
 (0)