Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
FROM docker.io/openshift/origin-release:golang-1.13 AS builder
WORKDIR /go/src/github.com/openshift/cincinnati-operator/
COPY . .
RUN go build -mod=vendor -o /tmp/build/updateservice-operator github.com/openshift/cincinnati-operator
RUN go build -mod=vendor -o /tmp/build/update-service-operator github.com/openshift/cincinnati-operator

FROM registry.access.redhat.com/ubi8/ubi-minimal:latest

COPY --from=builder /tmp/build/updateservice-operator /usr/bin/updateservice-operator
ENTRYPOINT ["/usr/bin/updateservice-operator"]
COPY --from=builder /tmp/build/update-service-operator /usr/bin/update-service-operator
ENTRYPOINT ["/usr/bin/update-service-operator"]
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@
build

SOURCES := $(shell find . -name '*.go' -not -path "*/vendor/*")
IMG ?= quay.io/updateservice/updateservice-operator:latest

# This is a placeholder for cincinnati-operator image placeholder
# During development override this when you want to use an specific image
# Example: IMG ?= quay.io/jottofar/updateservice-operator-index:v1
IMG ?= controller:latest

clean:
@echo "Cleaning previous outputs"
Expand All @@ -25,4 +29,4 @@ unit-test:
go test -v ./controllers/...

build: $(SOURCES)
go build -i -ldflags="-s -w" -mod=vendor -o ./updateservice-operator ./
go build -i -ldflags="-s -w" -mod=vendor -o ./update-service-operator ./
2 changes: 1 addition & 1 deletion PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ resources:
kind: UpdateService
version: v1
version: 3-alpha
projectName: updateservice-operator
projectName: update-service-operator
plugins:
go.sdk.operatorframework.io/v2-alpha: {}
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# updateservice-operator
# update-service-operator

This operator is developed using the [operator SDK][operator-sdk], version 1.0.0.
Installation docs are [here][operator-sdk-installation].
Expand All @@ -8,25 +8,25 @@ Installation docs are [here][operator-sdk-installation].
To run locally, you must set the operand image as shown below.

```
export OPERAND_IMAGE="quay.io/app-sre/updateservice:2873c6b"
export OPERAND_IMAGE="quay.io/app-sre/cincinnati:2873c6b"
operator-sdk run --local
```

## Using an init container to load graph data

The UpdateService graph data is loaded from an init container. Before deploying
the updateservice-operator, you will need to [build and push an init container containing the graph data](docs/graph-data-init-container.md).
the update-service-operator, you will need to [build and push an init container containing the graph data](docs/graph-data-init-container.md).

## Deploy operator

```
make deploy
```

By default, operator will be deployed using the default operator image `quay.io/updateservice/updateservice-operator:latest`. If you want to override the default operator image with your image, set
By default, operator will be deployed using the default operator image `quay.io/updateservice/update-service-operator:latest`. If you want to override the default operator image with your image, set

```
export OPERATOR_IMAGE="your-registry/your-repo/your-updateservice-opertor-image:tag"
export OPERATOR_IMAGE="your-registry/your-repo/your-update-service-opertor-image:tag"
```

## Run functional tests
Expand Down
2 changes: 1 addition & 1 deletion config/manager/manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ spec:
serviceAccountName: updateservice-operator
containers:
- name: updateservice-operator
image: quay.io/updateservice/updateservice-operator:latest
image: controller:latest
imagePullPolicy: Always
env:
- name: WATCH_NAMESPACE
Expand Down
4 changes: 3 additions & 1 deletion hack/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

set -e

DEFAULT_OPERATOR_IMAGE="quay.io/updateservice/updateservice-operator:latest"
# DEFAULT_OPERATOR_IMAGE is a placeholder for cincinnati-operator image placeholder
# During development override this when you want to use an specific image
DEFAULT_OPERATOR_IMAGE="controller:latest"
DEFAULT_OPERAND_IMAGE="quay.io/app-sre/cincinnati:2873c6b"

OPERATOR_IMAGE="${OPERATOR_IMAGE:-${DEFAULT_OPERATOR_IMAGE}}"
Expand Down