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
@@ -19,147 +19,156 @@ Follow these steps to determine if this issue is affecting your cluster:
19
19
5.`kubectl describe pod <pod id> --namespace <pod namespace>`
20
20
6. Under the events section, if you see error events related to docker hub rate limiting, then your cluster is likely affected by the rate limiting
21
21
22
-
We are actively working on a long term resolution to this problem. In the meantime, there are two ways to avoid this issue:
22
+
There are three ways to avoid this issue:
23
23
24
-
## Paid Docker Hub subscription
24
+
## Use Cortex images from quay.io
25
25
26
-
One option is to pay for the Docker Hub subscription to remove the limit on the number of image pulls. Docker Hub's updated pricing model allows unlimited pulls on a _Pro_ subscription for individuals as described [here](https://www.docker.com/pricing).
26
+
In response to Docker Hub's new image pull policy, we have migrated our images to [quay.io](https://quay.io). This registry allows for unlimited image pulls for unauthenticated users.
27
27
28
-
By default, the Cortex cluster pulls the images as an anonymous user. Follow [this guide](private-docker.md)to configure your Cortex cluster to pull the images as an authenticated user.
28
+
It is possible to configure Cortex to use the images from Quay instead of Docker Hub:
29
29
30
-
## Push to AWS ECR (Elastic Container Registry)
30
+
### Update your cluster configuration file
31
+
32
+
Add the following to your [cluster configuration file](../cluster-management/config.md) (e.g. `cluster.yaml`). In the image paths below, make sure to set `<VERSION>` to your cluster's version.
For Cortex cluster version < `0.16.0`, please upgrade your cluster to the latest version.
60
+
61
+
Once you've updated your cluster configuration file, you can spin up your cluster (e.g. `cortex cluster up --config cluster.yaml`).
62
+
63
+
### Update your API configuration file(s)
64
+
65
+
To configure your APIs to use the Quay images, you cna update your [API configuration files](../deployments/realtime-api/api-configuration.md). The image paths are specified in `predictor.image` (and `predictor.tensorflow_serving_image` for APIs with `kind: tensorflow`). Be advised that by default, the Docker Hub images are used for your predictors, so you will need to specify the Quay image paths for all of your APIs.
66
+
67
+
Here is a list of available images (make sure to set `<VERSION>` to your cluster's version):
Another option is to pay for the Docker Hub subscription to remove the limit on the number of image pulls. Docker Hub's updated pricing model allows unlimited pulls on a _Pro_ subscription for individuals as described [here](https://www.docker.com/pricing).
93
+
94
+
The advantage of this approach is that there's no need to do a `cortex cluster down`/`cortex cluster up` to authenticate with your Docker Hub account.
31
95
32
-
You can configure the Cortex cluster to use images from a different registry. A good choice is ECR on AWS. When an ECR repository resides in the same region as your Cortex cluster, there are no costs incurred when pulling images.
96
+
By default, the Cortex cluster pulls the images as an anonymous user. To configure your Cortex cluster to pull the images as an authenticated user, follow these steps:
33
97
34
98
### Step 1
35
99
36
-
Make sure you have the [aws](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv1.html) and [docker](https://docs.docker.com/get-docker/) CLIs installed.
100
+
Install and configure kubectl ([instructions](kubectl-setup.md)).
37
101
38
102
### Step 2
39
103
40
-
Export the `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`environment variables in your current shell, or run `aws configure`. These credentials must have access to push to ECR.
104
+
Set the following environment variables, replacing the placeholders with your docker username and password:
You can use the script below to push the images from Docker Hub to your ECR registry. Make sure to update the `ecr_region`, `aws_account_id`, and `cortex_version` variables at the top of the file. Copy-paste the contents into a new file (e.g. `ecr.sh`), and then run `chmod +x ecr.sh`, followed by `./ecr.sh`. It is recommended to run this from an EC2 instance in the same region as your ECR repository, since it will be much faster.
The first list of images that were printed (the cluster images) can be directly copy-pasted in your [cluster configuration file](../cluster-management/config.md) before spinning up your cluster.
153
+
Then repeat step 2 above with your updated credentials.
156
154
157
-
The second list of images that were printed (the API images) can be used in your [API configuration files](../deployments/realtime-api/api-configuration.md). The images are specified in `predictor.image` (and `predictor.tensorflow_serving_image` for APIs with `kind: tensorflow`). Be advised that by default, the Docker Hub images are used for your predictors, so you will need to specify your ECR image paths for all of your APIs.
155
+
### Removing your credentials
158
156
159
-
## Step 6
157
+
To remove your docker credentials from the cluster, run the following commands:
160
158
161
-
Spin up your Cortex cluster using your updated cluster configuration file (e.g. `cortex cluster up --config cluster.yaml`).
You can delete your ECR images from the [AWS ECR dashboard](https://console.aws.amazon.com/ecr/repositories) (set your region in the upper right corner). Make sure all of your Cortex clusters have been deleted before deleting any ECR images.
174
+
You can also push the Cortex images to ECR on your AWS account, and pull from your ECR repository in your cluster. Follow [this guide](self-hosted-images.md) to do this.
0 commit comments