-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate Buildkite CI queues from AWS to GKE #878
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -1,76 +1,146 @@ | ||
container: | ||
kubernetes: &kubernetes | ||
gitEnvFrom: | ||
- secretRef: | ||
name: oss-github-ssh-credentials | ||
sidecars: | ||
- image: us-west1-docker.pkg.dev/ci-compute/buildkite-images/buildkite-dind:v1 | ||
volumeMounts: | ||
- mountPath: /var/run/ | ||
name: docker-sock | ||
securityContext: | ||
privileged: true | ||
allowPrivilegeEscalation: true | ||
mirrorVolumeMounts: true # CRITICAL: this must be at the same indentation level as sidecars | ||
podSpec: &podSpec | ||
containers: | ||
- &commandContainer | ||
image: us-west1-docker.pkg.dev/ci-compute/buildkite-images/buildkite-command-container:v2 | ||
command: | ||
- |- | ||
echo "Command step was not overridden." | ||
exit 1 | ||
volumeMounts: | ||
- mountPath: /var/run/ | ||
name: docker-sock | ||
resources: | ||
requests: | ||
cpu: 7500m | ||
memory: 30G | ||
volumes: | ||
- name: docker-sock | ||
emptyDir: {} | ||
|
||
agents: | ||
queue: buildkite-gcp | ||
|
||
steps: | ||
- label: "fossa analyze" | ||
agents: | ||
queue: "init" | ||
docker: "*" | ||
command: ".buildkite/scripts/fossa.sh" | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
.buildkite/scripts/fossa.sh | ||
|
||
- label: "Lint Check" | ||
agents: | ||
queue: "init" | ||
docker: "*" | ||
command: ".buildkite/scripts/lint.sh" | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
.buildkite/scripts/lint.sh | ||
- docker-compose#v3.0.0: | ||
run: unit-test-test-service | ||
config: docker/buildkite/docker-compose.yaml | ||
|
||
- label: ":java: Unit test with test services" | ||
agents: | ||
queue: "workers" | ||
docker: "*" | ||
command: "./gradlew --no-daemon test jacocoTestReport" | ||
artifact_paths: | ||
- "build/reports/jacoco/test/*.xml" | ||
timeout_in_minutes: 15 | ||
timeout_in_minutes: 30 | ||
retry: | ||
automatic: | ||
- exit_status: "*" | ||
limit: 3 | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
./gradlew --no-daemon test jacocoTestReport | ||
- docker-compose#v3.0.0: | ||
run: unit-test-test-service | ||
config: docker/buildkite/docker-compose.yaml | ||
|
||
- label: ":java: Unit test with docker services sticky on" | ||
agents: | ||
queue: "workers" | ||
docker: "*" | ||
command: "./gradlew --no-daemon test" | ||
timeout_in_minutes: 15 | ||
timeout_in_minutes: 30 | ||
retry: | ||
automatic: | ||
- exit_status: "*" | ||
limit: 3 | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
./gradlew --no-daemon test | ||
- docker-compose#v3.0.0: | ||
run: unit-test-docker-sticky-on | ||
config: docker/buildkite/docker-compose.yaml | ||
|
||
- label: ":java: Unit test with docker services sticky off" | ||
agents: | ||
queue: "workers" | ||
docker: "*" | ||
command: "./gradlew --no-daemon test" | ||
timeout_in_minutes: 15 | ||
timeout_in_minutes: 30 | ||
retry: | ||
automatic: | ||
- exit_status: "*" | ||
limit: 3 | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
./gradlew --no-daemon test | ||
- docker-compose#v3.0.0: | ||
run: unit-test-docker-sticky-off | ||
config: docker/buildkite/docker-compose.yaml | ||
|
||
- wait | ||
|
||
- label: ":java: Report test coverage" | ||
agents: | ||
queue: "workers" | ||
docker: "*" | ||
command: ".buildkite/scripts/coverage.sh" | ||
retry: | ||
automatic: | ||
- exit_status: "*" | ||
limit: 3 | ||
plugins: | ||
- kubernetes: | ||
<<: *kubernetes | ||
podSpec: | ||
<<: *podSpec | ||
containers: | ||
- <<: *commandContainer | ||
command: | ||
- |- | ||
.buildkite/scripts/coverage.sh | ||
- docker-compose#v3.0.0: | ||
run: test-coverage-report | ||
config: docker/buildkite/docker-compose.yaml |
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we expect CI jobs to take longer on GKE?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does seem a bit flakier when leaving the timeout as is, so I bumped it. I don't have a concrete root cause, but the current theory is moving from VM based infra on AWS where you have dedicated bandwidth to a k8s cluster with potentially many containers competing for bandwidth could be part of the issue. CPU / Memory resources were configured to closely match what was available on AWS.