-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
Add initial CI subsystem documentation #415
Merged
Merged
Changes from all commits
Commits
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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
|
||
Our CI infrastructure is built around [BuildKite](https://buildkite.com) with some | ||
additional GitHub integration provided by https://github.com/mvines/ci-gate | ||
|
||
## Buildkite AWS CloudFormation Setup | ||
|
||
We use AWS CloudFormation to scale machines up and down based on the current CI | ||
load. If no machine is currently running it can take up to 60 seconds to spin | ||
up a new instance, please remain calm during this time. | ||
|
||
### Agent Queues | ||
|
||
We define two [Agent Queues](https://buildkite.com/docs/agent/v3/queues): | ||
`queue=default` and `queue=cuda`. The `default` queue should be favored and | ||
runs on lower-cost CPU instances. The `cuda` queue is only necessary for | ||
running **tests** that depend on GPU (via CUDA) access -- CUDA builds may still | ||
be run on the `default` queue, and the [buildkite artifact | ||
system](https://buildkite.com/docs/builds/artifacts) used to transfer build | ||
products over to a GPU instance for testing. | ||
|
||
### AMI | ||
We use a custom AWS AMI built via https://github.com/solana-labs/elastic-ci-stack-for-aws/tree/solana/cuda. | ||
|
||
Use the following process to update this AMI as dependencies change: | ||
```bash | ||
$ export AWS_ACCESS_KEY_ID=my_access_key | ||
$ export AWS_SECRET_ACCESS_KEY=my_secret_access_key | ||
$ git clone https://github.com/solana-labs/elastic-ci-stack-for-aws.git -b solana/cuda | ||
$ cd elastic-ci-stack-for-aws/ | ||
$ make build | ||
$ make build-ami | ||
``` | ||
|
||
Watch for the *"amazon-ebs: AMI:"* log message to extract the name of the new | ||
AMI. For example: | ||
``` | ||
amazon-ebs: AMI: ami-07118545e8b4ce6dc | ||
``` | ||
The new AMI should also now be visible in your EC2 Dashboard. Go to the desired | ||
AWS CloudFormation stack, update the **ImageId** field to the new AMI id, and | ||
*apply* the stack changes. | ||
|
||
|
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.
🥇