address comments

Signed-off-by: Jessica Yao <jessica@heptio.com>
This commit is contained in:
Jessica Yao
2017-08-16 14:03:05 -07:00
parent e19d964042
commit ef9eafacb4
2 changed files with 14 additions and 7 deletions

View File

@@ -23,7 +23,7 @@ BIN_DIR = $(OUTPUT_DIR)/bin
# docker related vars
DOCKER ?= docker
REGISTRY ?= gcr.io/heptio-images
BUILD_IMAGE ?= $(REGISTRY)/golang:1.8-alpine3.6
BUILD_IMAGE ?= gcr.io/heptio-images/golang:1.8-alpine3.6
# go build -i installs compiled packages so they can be reused later.
# This speeds up recompiles.
BUILDCMD = go build -i -v -ldflags "-X $(GOTARGET)/pkg/buildinfo.Version=$(VERSION) -X $(GOTARGET)/pkg/buildinfo.DockerImage=$(REGISTRY)/$(PROJECT)"

View File

@@ -21,13 +21,9 @@ The files are installed in `$GOPATH/src/github.com/heptio/ark`.
## 2. Build
### Using a locally built image
You can build your Ark image locally on the machine where you run your cluster, or you can push it to a private registry. This section covers both workflows.
To ensure that your Ark deployment uses your local image rather than pulling from an image registry, you'll need to explicitly set the `spec.template.spec.containers[*].imagePullPolicy` in your deployment file to `IfNotPresent`. This file is either `examples/azure/00-ark-deployment.yaml` if you're using Azure, or `examples/common/10-deployment.yaml` for all other cloud providers.
### Using your own registry
If you want to push the Heptio Ark images to your own registry, set the `$REGISTRY` environment variable (used in the `Makefile`). This allows any node in your cluster to pull your locally built image.
Set the `$REGISTRY` environment variable (used in the `Makefile`) if you want to push the Heptio Ark images to your own registry. This allows any node in your cluster to pull your locally built image.
`$PROJECT` and `$VERSION` environment variables are also specified in the `Makefile`, and can be similarly modified as desired.
@@ -39,6 +35,9 @@ sudo make all
To push your image to a registry, use `make push`.
## 3. Run
### Considerations
When running Heptio Ark, you will need to account for the following (all of which are handled in the [`/examples`][6] manifests):
* Appropriate RBAC permissions in the cluster
* *Read access* for all data from the source cluster and namespaces
@@ -50,6 +49,14 @@ When running Heptio Ark, you will need to account for the following (all of whic
See [Cloud Provider Specifics][9] for a more detailed guide.
### Specifying your image
Once your Ark deployment is up and running, **you need to replace the Heptio-provided Ark image with the specific one that you built.** You can do so with the following command:
```
kubectl set image deployment/ark ark=$REGISTRY/$PROJECT:$VERSION
```
where `$REGISTRY`, `$PROJECT`, and `$VERSION` match what you used in the [build step][3].
[0]: ../README.md
[1]: #0-prerequisites
[2]: #1-download