Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

godeps: run go mod tidy and vendor for dependencies #122

Merged
merged 1 commit into from
Mar 27, 2024

Conversation

leelavg
Copy link
Contributor

@leelavg leelavg commented Mar 27, 2024

PR #121 bumped the ocs-op dependency but didn't update the vendor, we had a sub target of go mod tidy and vendor before building image and so CI passed silently and failed d/s where only vendor folder is used.

PR red-hat-storage#121 bumped the ocs-op dependency but didn't update the vendor, we
had a sub target of go mod tidy and vendor before building image and so
CI passed silently and failed d/s where only vendor folder is used.

Signed-off-by: Leela Venkaiah G <[email protected]>
@leelavg
Copy link
Contributor Author

leelavg commented Mar 27, 2024

Local build of image w/ only cached vendor:

Removed the sub target which updates vendor for testing locally

# gd
diff --git a/Makefile b/Makefile
index c5233a1..c65b100 100644
--- a/Makefile
+++ b/Makefile
@@ -82,7 +82,7 @@ go-build: ## Run go build against code.
 run: manifests generate fmt vet ## Run a controller from your host.
        go run ./main.go
 
-container-build: test-setup ## Build container image with the manager.
+container-build: ## Build container image with the manager.
        docker build -t ${IMG} .
 
 container-push: ## Push container image with the manager.
# make container-build 
docker build -t quay.io/rhn_support_lgangava/code:client-unified-1 .
[+] Building 170.0s (23/23) FINISHED                                                                                                                           docker:default
 => [internal] load build definition from Dockerfile                                                                                                                     0.0s
 => => transferring dockerfile: 921B                                                                                                                                     0.0s
 => [internal] load metadata for gcr.io/distroless/static:nonroot                                                                                                        0.8s
 => [internal] load metadata for docker.io/library/golang:1.21                                                                                                           2.0s
 => [auth] library/golang:pull token for registry-1.docker.io                                                                                                            0.0s
 => [internal] load .dockerignore                                                                                                                                        0.0s
 => => transferring context: 171B                                                                                                                                        0.0s
 => [internal] load build context                                                                                                                                        1.2s
 => => transferring context: 53.29MB                                                                                                                                     1.2s
 => CACHED [stage-1 1/4] FROM gcr.io/distroless/static:nonroot@sha256:55c636171053dbc8ae07a280023bd787d2921f10e569f3e319f1539076dbba11                                   0.0s
 => [builder  1/13] FROM docker.io/library/golang:1.21@sha256:856073656d1a517517792e6cdd2f7a5ef080d3ca2dff33e518c8412f140fdd2d                                           0.0s
 => CACHED [builder  2/13] WORKDIR /workspace                                                                                                                            0.0s
 => [builder  3/13] COPY go.mod go.sum ./                                                                                                                                1.9s
 => [builder  4/13] COPY vendor/ vendor/                                                                                                                                 1.7s
 => [builder  5/13] COPY main.go Makefile ./                                                                                                                             0.5s
 => [builder  6/13] COPY hack/ hack/                                                                                                                                     0.2s
 => [builder  7/13] COPY api/ api/                                                                                                                                       0.1s
 => [builder  8/13] COPY controllers/ controllers/                                                                                                                       0.2s
 => [builder  9/13] COPY config/ config/                                                                                                                                 0.3s
 => [builder 10/13] COPY pkg/ pkg/                                                                                                                                       0.2s
 => [builder 11/13] COPY service/ service/                                                                                                                               0.1s
 => [builder 12/13] RUN make go-test                                                                                                                                    83.0s
 => [builder 13/13] RUN make go-build                                                                                                                                   74.7s
 => [stage-1 2/4] COPY --from=builder /workspace/bin/manager .                                                                                                           0.1s 
 => [stage-1 3/4] COPY --from=builder /workspace/bin/status-reporter .                                                                                                   0.1s 
 => exporting to image                                                                                                                                                   0.9s
 => => exporting layers                                                                                                                                                  0.9s
 => => writing image sha256:10ac448a27e101c28645d96b0b33de8ff9cbfc62ca3184100440d37fcf2321de                                                                             0.0s
 => => naming to quay.io/rhn_support_lgangava/code:client-unified-1                                                                                                      0.0s

Copy link

openshift-ci bot commented Mar 27, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: leelavg, Madhu-1

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit a79f241 into red-hat-storage:main Mar 27, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants