Skip to content

Commit

Permalink
NO-ISSUE: Create only one image
Browse files Browse the repository at this point in the history
Currently we create two images:

- `quay.io/openshift-kni/oran-o2ims` - For the servers.
- `quay.io/openshift-kni/oran-o2ims-operator` - For the operator.

But both contain the same `oran-o2ims` binary. The servers and the
operator are just sub-commands of that binary. For example, the
deployment manager server is the `start deployment-manager-server`
sub-command and the operator is the `start controller-manager` command.

To simplify things this patch removes one of the images. The preserved
image name is `oran-o2ims-operator`.

Related: openshift/release#54191
Signed-off-by: Juan Hernandez <[email protected]>
  • Loading branch information
jhernand authored and donpenney committed Aug 29, 2024
1 parent 02ea96d commit a46d744
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 126 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check-pull-request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
uses: actions/checkout@v4

- name: Build image
run: make image
run: make docker-build

unit-tests:
name: Unit tests
Expand Down
66 changes: 0 additions & 66 deletions Containerfile

This file was deleted.

46 changes: 0 additions & 46 deletions Containerfile.tools

This file was deleted.

12 changes: 0 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
# the License.
#

# Details of the image:
image_repo:=quay.io/openshift-kni/oran-o2ims
image_tag:=4.16.0

# Additional flags to pass to the `ginkgo` command.
ginkgo_flags:=

Expand Down Expand Up @@ -295,14 +291,6 @@ catalog-push: ## Push a catalog image.
binary:
go build -mod=vendor

.PHONY: image
image:
podman build -t "$(image_repo):$(image_tag)" -f Containerfile .

.PHONY: push
push: image
podman push "$(image_repo):$(image_tag)"

.PHONY: generate
go-generate:
go generate ./...
Expand Down
2 changes: 1 addition & 1 deletion internal/cmd/operator/start_controller_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func ControllerManager() *cobra.Command {
flags.StringVar(
&c.image,
imageFlagName,
"quay.io/openshift-kni/oran-o2ims:latest",
"quay.io/openshift-kni/oran-o2ims-operator:latest",
"Reference of the container image containing the servers.",
)
return result
Expand Down

0 comments on commit a46d744

Please sign in to comment.