You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+60-22Lines changed: 60 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -134,6 +134,8 @@ git diff # there should be no diff
134
134
135
135
### Cluster configuration
136
136
137
+
These instructions assume you'll be creating clusters on AWS and GCP. You may skip some of the steps and configuration if you'll only be developing / testing on a single cloud provider.
138
+
137
139
Create a config directory in the repo's root directory:
138
140
139
141
```bash
@@ -146,9 +148,14 @@ Create `dev/config/env.sh` with the following information:
146
148
# dev/config/env.sh
147
149
148
150
export AWS_ACCOUNT_ID="***"# you can find your account ID in the AWS web console; here is an example: 764403040417
149
-
export AWS_REGION="us-west-2"# you can use any AWS region you'd like
151
+
export AWS_REGION="***"# you can use any AWS region you'd like, e.g. "us-west-2"
150
152
export AWS_ACCESS_KEY_ID="***"
151
153
export AWS_SECRET_ACCESS_KEY="***"
154
+
155
+
export GCP_PROJECT_ID="***"
156
+
export GOOGLE_APPLICATION_CREDENTIALS="***"
157
+
export GCR_HOST="gcr.io"# must be "gcr.io", "us.gcr.io", "eu.gcr.io", or "asia.gcr.io"
158
+
152
159
# export NUM_BUILD_PROCS=2 # optional; can be >2 if you have enough memory
153
160
```
154
161
@@ -158,41 +165,68 @@ Create the ECR registries:
158
165
make registry-create-aws
159
166
```
160
167
161
-
Create `dev/config/cluster-aws.yaml`. Paste the following config, and update `cortex_region` and all registry URLs (replace `XXXXXXXX` with your AWS account ID, and update the region):
168
+
Create `dev/config/cluster-aws.yaml`. Paste the following config, and update `region` and all registry URLs (replace `<account_id>` with your AWS account ID, and replace `<region>` with your region):
Create `dev/config/cluster-gcp.yaml`. Paste the following config, and update `project`, `zone`, and all registry URLs (replace `<project_id>` with your project ID, and update `gcr.io` if you are using a different host):
alias cortex='$HOME/bin/cortex' # your path may be different depending on where you cloned the repo
198
232
```
@@ -213,12 +247,16 @@ cortex version # should show "master"
213
247
Build and push all Cortex images:
214
248
215
249
```bash
250
+
# for AWS:
216
251
make images-all-aws
252
+
253
+
# for GCP:
254
+
make images-all-gcp
217
255
```
218
256
219
257
## Dev workflow
220
258
221
-
Here is the typical full dev workflow which covers most cases:
259
+
Here is the typical full dev workflow which covers most cases (replace `aws` with `gcp` if desired):
222
260
223
261
1.`make cluster-up-aws` (creates a cluster using `dev/config/cluster-aws.yaml`)
224
262
2.`make devstart-aws` (deletes the in-cluster operator, builds the CLI, and starts the operator locally; file changes will trigger the CLI and operator to re-build)
@@ -230,7 +268,7 @@ Here is the typical full dev workflow which covers most cases:
230
268
If you want to switch back to the in-cluster operator:
231
269
232
270
1.`<ctrl+c>` to stop your local operator
233
-
2.`make cluster-configure-aws` to install the operator in your cluster
271
+
2.`make operator-start-aws` to restart the operator in your cluster
234
272
235
273
If you only want to test Cortex's local environment, here is the common workflow:
Copy file name to clipboardExpand all lines: docs/workloads/dependencies/docker-images.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Docker images
2
2
3
-
You can build a custom Docker image for use in your APIs, e.g. to avoid installing dependencies during replica initialization.
3
+
You can build a custom Docker image for use in your APIs, e.g. to avoid installing dependencies during replica initialization or to have smaller images.
0 commit comments