-
Notifications
You must be signed in to change notification settings - Fork 23
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
Update tekton configuration and add a new dockerfile for downstream build #47
Open
Mangaal
wants to merge
11
commits into
redhat-developer:master
Choose a base branch
from
Mangaal:enable-konflux
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 3 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
c49931b
add Containerfile.plugin and update tekton config for docker file for…
Mangaal 958fcdd
update Containerfile.plugin file path
Mangaal c0841d6
update konflux config
Mangaal 79e6ea0
update tekon config
Mangaal 29ceb85
update build file
Mangaal 571e42f
update tekon config
Mangaal 432a0ad
remove extra space
Mangaal 8545440
fix ci error
Mangaal c600d96
check without hermetic
Mangaal 18da3bf
enable hermetic
Mangaal c92ca9a
add toolchain
Mangaal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Build Stage | ||
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_8_golang_1.22 AS builder | ||
WORKDIR /go/src | ||
COPY . /go/src | ||
RUN GIT_COMMIT=$(git rev-parse HEAD) && \ | ||
CGO_ENABLED=0 GOOS=linux go build -a -mod=readonly \ | ||
-ldflags "-X github.com/redhat-developer/gitops-backend/pkg/health.GitRevision=${GIT_COMMIT}" ./cmd/backend-http | ||
|
||
# Final Stage | ||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
WORKDIR / | ||
COPY --from=builder /go/src/backend-http . | ||
EXPOSE 8080 | ||
ENTRYPOINT ["./backend-http"] | ||
|
||
LABEL \ | ||
name="openshift-gitops-1/gitops-rhel8" \ | ||
version=${CI_CONTAINER_VERSION} \ | ||
License="Apache 2.0" \ | ||
com.redhat.component="openshift-gitops-container" \ | ||
com.redhat.delivery.appregistry="false" \ | ||
release=${CI_CONTAINER_RELEASE} \ | ||
upstream-version=${CI_UPSTREAM_VERSION} \ | ||
upstream-vcs-ref="${CI_GITOPS_BACKEND_UPSTREAM_COMMIT}" \ | ||
upstream-vcs-type="git" \ | ||
summary="Red Hat OpenShift GitOps Backend Service" \ | ||
io.openshift.expose-services="" \ | ||
io.openshift.tags="openshift,gitops" \ | ||
io.k8s.display-name="Red Hat OpenShift GitOps Backend Service" \ | ||
maintainer="William Tam <[email protected]>" \ | ||
description="Red Hat OpenShift GitOps Backend Service" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -26,8 +26,18 @@ spec: | |||||||
value: quay.io/redhat-user-workloads/rh-openshift-gitops-tenant/openshift-gitops-operator/gitops-backend:on-pr-{{revision}} | ||||||||
- name: image-expires-after | ||||||||
value: 5d | ||||||||
- name: hermetic | ||||||||
value: "true" | ||||||||
- name: prefetch-input | ||||||||
value: '{"type": "gomod", "path": "."}' | ||||||||
- name: build-platforms | ||||||||
value: | ||||||||
- linux/x86_64 | ||||||||
- linux/arm64 | ||||||||
- linux/ppc64le | ||||||||
- linux/s390x | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Let's run PR builds only on amd64. I noticed long delays in setting up build env for non amd archs. |
||||||||
- name: dockerfile | ||||||||
value: Dockerfile | ||||||||
value: .konflux/Containerfile.plugin | ||||||||
pipelineSpec: | ||||||||
description: | | ||||||||
This pipeline is ideal for building multi-arch container images from a Containerfile while maintaining trust after pipeline customization. | ||||||||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need to find replacements for
CI_*
env vars. If I am not wrong, these vars are CPAAS specific. We need to figure out konflux equivalent for these or manually define them.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @svghadi , you are right, I will try to find konflux equivalent for these
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even I need them for dex builds. Let me know if you find them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can address this during release pipeline configurations, shouldn't be a blocker for merging this PR.