-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2d3c5e8
commit d6d5e1f
Showing
12 changed files
with
80 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,8 @@ on: | |
|
||
permissions: | ||
contents: read | ||
repository-projects: read | ||
packages: read | ||
|
||
concurrency: | ||
group: ci-${{ github.ref }}-tests | ||
|
@@ -19,8 +21,8 @@ jobs: | |
build: | ||
runs-on: ubuntu-latest | ||
env: | ||
GOPRIVATE: github.com/fabianMendez/privatemodule | ||
GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} | ||
GOPRIVATE: github.com/sedaprotocol/vrf-go | ||
PAT: ${{ secrets.PAT }} | ||
strategy: | ||
matrix: | ||
arch: [amd64, arm64] | ||
|
@@ -49,7 +51,9 @@ jobs: | |
env: | ||
GOOS: ${{ matrix.targetos }} | ||
GOARCH: ${{ matrix.arch }} | ||
- run: git config --global url.https://[email protected]/.insteadOf https://github.com/ | ||
- name: Configure private token | ||
run: | | ||
git config --global url."https://${PAT}@github.com/".insteadOf "https://github.com/" | ||
- name: Compile | ||
if: steps.cache-binaries.outputs.cache-hit != 'true' && env.GIT_DIFF | ||
run: | | ||
|
@@ -59,8 +63,8 @@ jobs: | |
tests: | ||
runs-on: ubuntu-latest | ||
env: | ||
GOPRIVATE: github.com/fabianMendez/privatemodule | ||
GH_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GOPRIVATE: github.com/sedaprotocol/vrf-go | ||
PAT: ${{ secrets.PAT }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v4 | ||
|
@@ -69,7 +73,7 @@ jobs: | |
check-latest: true | ||
cache: true | ||
cache-dependency-path: go.sum | ||
- run: git config --global url.https://$GITHUB_TOKEN@github.com/.insteadOf https://github.com/ | ||
- run: git config --global url.https://${PAT}@github.com/.insteadOf https://github.com/ | ||
- uses: technote-space/[email protected] | ||
id: git_diff | ||
with: | ||
|
@@ -93,23 +97,28 @@ jobs: | |
test-e2e: | ||
runs-on: ubuntu-latest | ||
env: | ||
GOPRIVATE: github.com/fabianMendez/privatemodule | ||
GH_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GOPRIVATE: github.com/sedaprotocol/vrf-go | ||
USERNAME: hacheigriega | ||
PAT: ${{ secrets.PAT }} | ||
timeout-minutes: 10 | ||
steps: | ||
- uses: actions/setup-go@v4 | ||
with: | ||
go-version: "1.21" | ||
- uses: actions/checkout@v4 | ||
- run: git config --global url.https://[email protected]/.insteadOf https://github.com/ | ||
- run: git config --global url.https://${GITHUB_TOKEN}@github.com/.insteadOf https://github.com/ | ||
- uses: technote-space/[email protected] | ||
with: | ||
PATTERNS: | | ||
**/**.go | ||
go.mod | ||
go.sum | ||
- name: Build e2e Docker Image | ||
run: make docker-build-e2e | ||
- name: Test E2E | ||
run: make test-e2e | ||
|
||
- name: Create .netrc file | ||
run: | | ||
echo "machine github.com" > ${GITHUB_WORKSPACE}/.netrc | ||
echo " login ${USERNAME}" >> ${GITHUB_WORKSPACE}/.netrc | ||
echo " password ${PAT}" >> ${GITHUB_WORKSPACE}/.netrc | ||
chmod 600 ${GITHUB_WORKSPACE}/.netrc | ||
- name: Test e2e | ||
run: | | ||
make test-e2e |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters