File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Publish to CodeArtifact
2+
3+ on :
4+ pull_request :
5+ paths : ['.github/workflows/publish-codeartifact.yml']
6+ workflow_dispatch :
7+
8+ permissions :
9+ id-token : write
10+ contents : read
11+
12+ jobs :
13+ publish :
14+ runs-on : ubuntu-latest
15+ steps :
16+ - uses : actions/checkout@v5
17+ - uses : astral-sh/setup-uv@v7
18+ - uses : aws-actions/configure-aws-credentials@v4
19+ with :
20+ role-to-assume : arn:aws:iam::084060095745:role/codeartifact-github-actions-production
21+ aws-region : eu-west-2
22+ - name : Get CodeArtifact token
23+ run : |
24+ TOKEN=$(aws codeartifact get-authorization-token \
25+ --domain flagsmith-production --domain-owner 084060095745 \
26+ --query authorizationToken --output text)
27+ echo "::add-mask::$TOKEN"
28+ echo "CODEARTIFACT_TOKEN=$TOKEN" >> "$GITHUB_ENV"
29+ - run : uv build
30+ - run : |
31+ uv publish \
32+ --publish-url https://flagsmith-production-084060095745.d.codeartifact.eu-west-2.amazonaws.com/pypi/flagsmith-pypi-production/ \
33+ --username aws --password "$CODEARTIFACT_TOKEN" \
34+ dist/*
You can’t perform that action at this time.
0 commit comments