Skip to content

Commit

Permalink
manager image patch
Browse files Browse the repository at this point in the history
  • Loading branch information
ctab committed Apr 29, 2019
1 parent 1538da4 commit 9efa568
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,7 @@ docker-push-release: docker-tag-release
docker-build:
docker build . -t ${IMG}
@echo "updating kustomize image patch file for manager resource"
cp ./config/manager/manager_image_patch.example.yaml ./config/manager/manager_image_patch.yaml
sed -i'' -e 's@image: .*@image: '"${IMG}"'@' ./config/manager/manager_image_patch.yaml
echo "#" > ./config/manager/manager_image_patch.yaml

docker-build-ci:
docker build . -t $(IMG) -f Dockerfile_ci
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,14 @@ Currently the most reliable way of installing Gatekeeper is to build and install

#### Deploying a Release using Prebuilt Image

If you want to deploy a released version of Gatekeeper in your cluster with a prebuilt image, then you can run the following command, substituting the url to your prebuilt image:

```
IMG=<YOUR DESIRED PREBUILT IMAGE URL>
cp ./config/manager/manager_image_patch.example.yaml ./config/manager/manager_image_patch.yaml
sed -i'' -e 's@image: .*@image: '"${IMG}"'@' ./config/manager/manager_image_patch.yaml
If you want to deploy a released version of Gatekeeper in your cluster with a prebuilt image, then first copy the following kustomize configuration patch:

```sh
cp config/manager/manager_image_patch.example.yaml config/manager/manager_image_patch.yaml
```

Then modify the new manager_image_patch.yaml file to point to your prebuilt image. Finally, run the following:

```sh
kubectl apply -f https://raw.githubusercontent.com/open-policy-agent/gatekeeper/master/deploy/gatekeeper-constraint.yaml
```
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# You can copy this file to manager_image_patch.yaml to specify a prebuilt image
apiVersion: apps/v1
kind: StatefulSet
metadata:
Expand Down

0 comments on commit 9efa568

Please sign in to comment.