Skip to content

Commit 6135ea9

Browse files
Rakshitha-KamathRakshitha-Kamath
authored andcommitted
promtail-8.1: This PR contains the following changes,
[1] Config changes to support multi-arch build [2] Additonal tag to differentiate between the ceph versions [3] Replace rhceph-dev to rhceph-ci Signed-off-by: Rakshitha-Kamath <[email protected]>
1 parent 57c3fc4 commit 6135ea9

File tree

4 files changed

+37
-11
lines changed

4 files changed

+37
-11
lines changed

.tekton/promtail-8-1-pull-request.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,15 @@ spec:
2424
- name: revision
2525
value: '{{revision}}'
2626
- name: output-image
27-
value: quay.io/rhceph-dev/promtail:on-pr-{{revision}}
27+
value: quay.io/rhceph-ci/promtail:on-pr-v8.1-{{revision}}
2828
- name: image-expires-after
2929
value: 5d
3030
- name: build-platforms
3131
value:
3232
- linux/x86_64
33+
- linux/arm64
34+
- linux/s390x
35+
- linux/ppc64le
3336
- name: dockerfile
3437
value: Dockerfile
3538
- name: path-context
@@ -554,6 +557,11 @@ spec:
554557
value: $(tasks.build-image-index.results.IMAGE_URL)
555558
- name: IMAGE_DIGEST
556559
value: $(tasks.build-image-index.results.IMAGE_DIGEST)
560+
- name: ADDITIONAL_TAGS
561+
value:
562+
- "pull-request-{{pull_request_number}}"
563+
- "from-branch-{{source_branch}}"
564+
- "{{target_branch}}-$(tasks.clone-repository.results.commit-timestamp)"
557565
runAfter:
558566
- build-image-index
559567
taskRef:

.tekton/promtail-8-1-push.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,13 @@ spec:
2323
- name: revision
2424
value: '{{revision}}'
2525
- name: output-image
26-
value: quay.io/rhceph-dev/promtail:{{revision}}
26+
value: quay.io/rhceph-ci/promtail:v8.1-{{revision}}
2727
- name: build-platforms
2828
value:
2929
- linux/x86_64
30+
- linux/arm64
31+
- linux/s390x
32+
- linux/ppc64le
3033
- name: dockerfile
3134
value: Dockerfile
3235
- name: path-context
@@ -551,6 +554,10 @@ spec:
551554
value: $(tasks.build-image-index.results.IMAGE_URL)
552555
- name: IMAGE_DIGEST
553556
value: $(tasks.build-image-index.results.IMAGE_DIGEST)
557+
- name: ADDITIONAL_TAGS
558+
value:
559+
- "v8.1"
560+
- "{{target_branch}}-$(tasks.clone-repository.results.commit-timestamp)"
554561
runAfter:
555562
- build-image-index
556563
taskRef:

Dockerfile

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,31 @@
1-
#FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_golang_1.21 AS builder
2-
FROM quay.io/projectquay/golang:1.24 AS builder
3-
COPY loki loki
4-
WORKDIR loki
1+
ARG REMOTE_SOURCE=loki
2+
ARG REMOTE_SOURCE_DIR=/go/app
3+
4+
FROM --platform=$BUILDPLATFORM quay.io/projectquay/golang:1.22 AS builder
5+
6+
# Build Arguments
7+
ARG REMOTE_SOURCE
8+
ARG REMOTE_SOURCE_DIR
9+
10+
COPY $REMOTE_SOURCE $REMOTE_SOURCE_DIR
11+
WORKDIR $REMOTE_SOURCE_DIR
512
RUN make clean && make BUILD_IN_CONTAINER=false promtail
613

714

8-
FROM registry.redhat.io/ubi9/ubi-micro
9-
# Standard Red Hat labels
15+
FROM --platform=$BUILDPLATFORM registry.access.redhat.com/ubi9-minimal:latest
16+
17+
# Build Arguments
18+
ARG REMOTE_SOURCE
19+
ARG REMOTE_SOURCE_DIR
20+
1021
LABEL com.redhat.component="promtail-container"
1122
LABEL name="promtail"
1223
LABEL version="v3.0.0"
1324
LABEL summary="Provides promtail container"
1425
LABEL io.k8s.display-name="Promtail container"
1526
LABEL maintainer="Guillaume Abrioux <[email protected]>"
1627
LABEL description="Responsible for gathering logs and sending them to Loki"
17-
COPY --from=builder go/loki/clients/cmd/promtail/promtail /usr/bin/promtail
18-
COPY --from=builder go/loki/clients/cmd/promtail/promtail-docker-config.yaml /etc/promtail/config.yml
28+
COPY --from=builder $REMOTE_SOURCE_DIR/clients/cmd/promtail/promtail /usr/bin/promtail
29+
COPY --from=builder $REMOTE_SOURCE_DIR/clients/cmd/promtail/promtail-docker-config.yaml /etc/promtail/config.yml
1930
ENTRYPOINT ["/usr/bin/promtail"]
2031
CMD ["-config.file=/etc/promtail/config.yml"]

loki

Submodule loki updated 13218 files

0 commit comments

Comments
 (0)