Skip to content

Commit

Permalink
1.13: backport ci fixes (#13958)
Browse files Browse the repository at this point in the history
    748b2ab (mac ci: try ignoring update failure (#13658), 2020-10-20)
    f95f539 (ci: various improvements (#13660), 2020-10-20)
    73d78f8 (ci: use multiple stage (#13557), 2020-10-15)
    b7a4756 (ci: use azp for api and go-control-plane sync (#13550), 2020-10-14)
    876a6bb (ci use azp to sync filter example (#13501), 2020-10-12)
    a0f31ee (ci: use azp to generate docs (#13481), 2020-10-12)
    a103da9 (test: fixing an integration test flake (#11845), 2020-07-01)

Signed-off-by: Lizan Zhou <lizan@tetrate.io>
  • Loading branch information
lizan authored Nov 13, 2020
1 parent 9a4a148 commit 14863ad
Show file tree
Hide file tree
Showing 21 changed files with 441 additions and 308 deletions.
37 changes: 29 additions & 8 deletions .azure-pipelines/bazel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,31 @@ parameters:
displayName: "CI target"
type: string
default: bazel.release
- name: artifactSuffix
displayName: "Suffix of artifact"
type: string
default: ""
- name: rbe
displayName: "Enable RBE"
type: boolean
default: true
- name: managedAgent
type: boolean
default: true
- name: bazelBuildExtraOptions
type: string
default: "--flaky_test_attempts=2"

steps:
- task: CacheBeta@1
- task: Cache@2
inputs:
key: '"${{ parameters.ciTarget }}" | ./WORKSPACE | **/*.bzl'
path: $(Build.StagingDirectory)/repository_cache
continueOnError: true

- bash: .azure-pipelines/cleanup.sh
displayName: "Removing tools from agent"
condition: ${{ parameters.managedAgent }}

- bash: |
echo "disk space at beginning of build:"
Expand All @@ -26,18 +42,23 @@ steps:
}' | sudo tee /etc/docker/daemon.json
sudo service docker restart
displayName: "Enable IPv6"
condition: ${{ parameters.managedAgent }}
- script: ci/run_envoy_docker.sh 'ci/do_ci.sh ${{ parameters.ciTarget }}'
workingDirectory: $(Build.SourcesDirectory)
env:
ENVOY_DOCKER_BUILD_DIR: $(Build.StagingDirectory)
ENVOY_RBE: "true"
# Use https://docs.bazel.build/versions/master/command-line-reference.html#flag--experimental_repository_cache_hardlinks
# to save disk space.
BAZEL_BUILD_EXTRA_OPTIONS: "--config=remote-ci --jobs=$(RbeJobs) --curses=no --experimental_repository_cache_hardlinks"
BAZEL_REMOTE_CACHE: grpcs://remotebuildexecution.googleapis.com
BAZEL_REMOTE_INSTANCE: projects/envoy-ci/instances/default_instance
GCP_SERVICE_ACCOUNT_KEY: $(GcpServiceAccountKey)
${{ if parameters.rbe }}:
ENVOY_RBE: "1"
# Use https://docs.bazel.build/versions/master/command-line-reference.html#flag--experimental_repository_cache_hardlinks
# to save disk space.
BAZEL_BUILD_EXTRA_OPTIONS: "--config=remote-ci --jobs=$(RbeJobs) --curses=no --experimental_repository_cache_hardlinks ${{ parameters.bazelBuildExtraOptions }}"
BAZEL_REMOTE_CACHE: grpcs://remotebuildexecution.googleapis.com
BAZEL_REMOTE_INSTANCE: projects/envoy-ci/instances/default_instance
GCP_SERVICE_ACCOUNT_KEY: $(GcpServiceAccountKey)
${{ if eq(parameters.rbe, false) }}:
BAZEL_BUILD_EXTRA_OPTIONS: "--curses=no --experimental_repository_cache_hardlinks ${{ parameters.bazelBuildExtraOptions }}"

displayName: "Run CI script"

- bash: |
Expand Down
5 changes: 3 additions & 2 deletions .azure-pipelines/cleanup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
set -e

# Temporary script to remove tools from Azure pipelines agent to create more disk space room.
sudo apt-get -y update
sudo apt-get purge -y 'ghc-*' 'zulu-*-azure-jdk' 'libllvm*' 'mysql-*' 'dotnet-*' 'cpp-*'
sudo apt-get update -y
sudo apt-get purge -y --no-upgrade 'ghc-*' 'zulu-*-azure-jdk' 'libllvm*' 'mysql-*' 'dotnet-*' 'libgl1' \
'adoptopenjdk-*' 'azure-cli' 'google-chrome-stable' 'firefox' 'hhvm'

dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -rn
Loading

0 comments on commit 14863ad

Please sign in to comment.