Skip to content

Commit

Permalink
ci(spanner): use airlock for presubmit jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
sakthivelmanii committed Jan 10, 2025
1 parent 592047f commit e391b62
Show file tree
Hide file tree
Showing 4 changed files with 102 additions and 3 deletions.
17 changes: 17 additions & 0 deletions .kokoro/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,23 @@ if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"continuous"* ]]; then
trap cleanup EXIT HUP
fi

set -x
if [[ $USE_AIRLOCK = 'true' ]]; then
cat > $HOME/.pypirc <<EOL
[distutils]
index-servers =
python-3p-trusted
[python-3p-trusted]
repository = https://us-python.pkg.dev/artifact-foundry-prod/python-3p-trusted/
EOL
mkdir -p $HOME/.config/pip
cat > $HOME/.config/pip/pip.conf <<EOL
[global]
index-url = https://us-python.pkg.dev/artifact-foundry-prod/python-3p-trusted/simple/
EOL
fi

# If NOX_SESSION is set, it only runs the specified session,
# otherwise run all the sessions.
if [[ -n "${NOX_SESSION:-}" ]]; then
Expand Down
5 changes: 5 additions & 0 deletions .kokoro/presubmit/system-3.8.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,9 @@
env_vars: {
key: "NOX_SESSION"
value: "system-3.8"
}

env_vars: {
key: "USE_AIRLOCK"
value: "true"
}
Loading

0 comments on commit e391b62

Please sign in to comment.