Configure CI to use GOPRIVATE for luxfi packages

- Set GOPRIVATE and GONOSUMDB for github.com/luxfi/* packages
- Configure git credentials with GITHUB_TOKEN
- Remove duplicate go mod download step from test job
This commit is contained in:
2025-12-04 08:52:25 -08:00
parent 3353331d98
commit 220c6a7e65
2 changed files with 20 additions and 3 deletions
+10 -3
View File
@@ -8,6 +8,8 @@ on:
env:
GO_VERSION: '1.25.5'
GOPRIVATE: github.com/luxfi/*
GONOSUMDB: github.com/luxfi/*
jobs:
lint:
@@ -31,6 +33,8 @@ jobs:
- name: Setup CI environment
run: ./ci_setup.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Install golangci-lint v2
run: |
@@ -79,9 +83,8 @@ jobs:
- name: Setup CI environment
run: ./ci_setup.sh
- name: Install dependencies
run: go mod download
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Run short tests
run: |
@@ -119,6 +122,8 @@ jobs:
- name: Setup CI environment
run: ./ci_setup.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build EVM
run: |
@@ -151,6 +156,8 @@ jobs:
- name: Setup CI environment
run: ./ci_setup.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Run gosec
uses: securego/gosec@master
+10
View File
@@ -7,6 +7,16 @@ echo "Setting up CI environment..."
echo "Go version:"
go version
# Configure GOPRIVATE for all luxfi packages
export GOPRIVATE=github.com/luxfi/*
export GONOSUMDB=github.com/luxfi/*
# Configure git to use GITHUB_TOKEN for authentication
if [ -n "$GITHUB_TOKEN" ]; then
echo "Configuring git credentials..."
git config --global url."https://x-access-token:${GITHUB_TOKEN}@github.com/".insteadOf "https://github.com/"
fi
# Download dependencies from published packages
echo "Downloading dependencies..."
go mod download