Skip to content

Commit

Permalink
Update README.md (#2317)
Browse files Browse the repository at this point in the history
To [avoid confusion for new user](#1337) trying `operator-sdk`, Improve README and replace `example` with `<username>`. 

Also add step to login to public registry like quay.io. If user is not logged in through CLI, He will face following error

`quay unauthorized: access to the requested resource is not authorized`

After login push work seamlessly.
  • Loading branch information
Shamsher Ansari authored and camilamacedo86 committed Dec 11, 2019
1 parent cea92d5 commit f9cb4c7
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,18 @@ $ operator-sdk add api --api-version=app.example.com/v1alpha1 --kind=AppService
$ operator-sdk add controller --api-version=app.example.com/v1alpha1 --kind=AppService

# Build and push the app-operator image to a public registry such as quay.io
$ operator-sdk build quay.io/example/app-operator
$ docker push quay.io/example/app-operator
$ operator-sdk build quay.io/<username>/app-operator

# Login to public registry such as quay.io
$ docker login quay.io

# Push image
$ docker push quay.io/<username>/app-operator

# Update the operator manifest to use the built image name (if you are performing these steps on OSX, see note below)
$ sed -i 's|REPLACE_IMAGE|quay.io/example/app-operator|g' deploy/operator.yaml
$ sed -i 's|REPLACE_IMAGE|quay.io/<username>/app-operator|g' deploy/operator.yaml
# On OSX use:
$ sed -i "" 's|REPLACE_IMAGE|quay.io/example/app-operator|g' deploy/operator.yaml
$ sed -i "" 's|REPLACE_IMAGE|quay.io/<username>/app-operator|g' deploy/operator.yaml

# Setup Service Account
$ kubectl create -f deploy/service_account.yaml
Expand Down

0 comments on commit f9cb4c7

Please sign in to comment.