Compare commits
24 Commits
Author | SHA1 | Date | |
---|---|---|---|
f99c9aae1d | |||
d9107d1a7b | |||
48c133f095 | |||
6f498eff58 | |||
621c2035c6 | |||
a165073521 | |||
16dcaef4f7 | |||
2579cc7f00 | |||
5d782faa02 | |||
7bd5dc4093 | |||
33d242f69a | |||
f7fcfd53ad | |||
6de66df1a9 | |||
dbdc24fe53 | |||
bda8c643c6 | |||
4161f32529 | |||
d504595922 | |||
a270f8481e | |||
c7bc209fd8 | |||
1c02becff6 | |||
2a2081b01b | |||
ab32348082 | |||
aa92aa43c1 | |||
1ec7cd94e2 |
@ -2,6 +2,9 @@
|
||||
|
||||
def call(Map config=[:]) {
|
||||
pipeline {
|
||||
options {
|
||||
disableConcurrentBuilds()
|
||||
}
|
||||
agent {
|
||||
node {
|
||||
label 'podman-aws-trivy'
|
||||
|
13
Dockerfile
13
Dockerfile
@ -2,7 +2,7 @@
|
||||
# https://hub.docker.com/r/jenkins/inbound-agent/tags
|
||||
|
||||
|
||||
FROM jenkins/inbound-agent:alpine-jdk17@sha256:4f78d4832acacddf3573b1095770f672ac0b2a76432002f9ade707e302f96a12
|
||||
FROM jenkins/inbound-agent:alpine-jdk21@sha256:ce5fe247069abd73c82d40ae5c6c400ead2c12f7be854be368d64893afc2663a
|
||||
|
||||
ARG BUILDUSER=jenkins
|
||||
|
||||
@ -32,8 +32,8 @@ ADD entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
# conf/registries.conf will be mounted RO at runtime to inherit worker settings incl. caching proxies
|
||||
ADD --chown=$BUILDUSER:$BUILDUSER conf/containers.conf conf/storage.conf /home/$BUILDUSER/.config/containers
|
||||
|
||||
RUN echo -e "$BUILDUSER:1:999\n$BUILDUSER:1001:64535" > /etc/subuid && \
|
||||
echo -e "$BUILDUSER:1:999\n$BUILDUSER:1001:64535" > /etc/subgid && \
|
||||
RUN echo -e "$BUILDUSER:100000:65535" > /etc/subuid && \
|
||||
echo -e "$BUILDUSER:100000:65535" > /etc/subgid && \
|
||||
cd /usr/bin && ln -s podman docker && \
|
||||
chown $BUILDUSER:$BUILDUSER -R /home/$BUILDUSER
|
||||
|
||||
@ -41,9 +41,14 @@ RUN echo -e "$BUILDUSER:1:999\n$BUILDUSER:1001:64535" > /etc/subuid && \
|
||||
RUN sed -i -e 's/exec \$JAVA_BIN/podman system service -t0\&\n exec \$JAVA_BIN/' /usr/local/bin/jenkins-agent
|
||||
|
||||
ENV XDG_RUNTIME_DIR=/home/$BUILDUSER/agent/xdg-run
|
||||
ENV XDG_CONFIG_HOME=/home/$BUILDUSER/.config
|
||||
|
||||
ENV BUILDAH_ISOLATION=chroot
|
||||
ENV _CONTAINERS_USERNS_CONFIGURED=""
|
||||
ENV HOME=/home/$BUILDUSER
|
||||
|
||||
# Until we setup the logging and metrics pipelines in OTEL
|
||||
ENV OTEL_LOGS_EXPORTER=none
|
||||
ENV OTEL_METRICS_EXPORTER=none
|
||||
|
||||
USER $BUILDUSER
|
||||
|
||||
|
2
Jenkinsfile
vendored
2
Jenkinsfile
vendored
@ -2,4 +2,4 @@ library identifier: 'zdt-lib@master', retriever: modernSCM(
|
||||
[$class: 'GitSCMSource',
|
||||
remote: 'https://git.zero-downtime.net/ZeroDownTime/ci-tools-lib.git'])
|
||||
|
||||
buildPodman name: 'jenkins-podman', trivyFail: 'NONE'
|
||||
buildPodman name: 'jenkins-podman'
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
|
||||
mkdir -p $HOME/agent/xdg-run $HOME/agent/containers/run $HOME/agent/containers/storage
|
||||
mkdir -p $XDG_RUNTIME_DIR
|
||||
/usr/local/bin/jenkins-agent
|
||||
|
10
junit.tpl
10
junit.tpl
@ -14,8 +14,12 @@
|
||||
</testcase>
|
||||
{{- end }}
|
||||
</testsuite>
|
||||
{{- $failures := len .Misconfigurations }}
|
||||
<testsuite tests="{{ $failures }}" failures="{{ $failures }}" name="{{ .Target }}" errors="0" skipped="0" time="">
|
||||
|
||||
{{- if .MisconfSummary }}
|
||||
<testsuite tests="{{ add .MisconfSummary.Successes .MisconfSummary.Failures }}" failures="{{ .MisconfSummary.Failures }}" name="{{ .Target }}" errors="0" skipped="{{ .MisconfSummary.Exceptions }}" time="">
|
||||
{{- else }}
|
||||
<testsuite tests="0" failures="0" name="{{ .Target }}" errors="0" skipped="0" time="">
|
||||
{{- end }}
|
||||
{{- if not (eq .Type "") }}
|
||||
<properties>
|
||||
<property name="type" value="{{ .Type }}"></property>
|
||||
@ -23,7 +27,9 @@
|
||||
{{- end -}}
|
||||
{{ range .Misconfigurations }}
|
||||
<testcase classname="{{ .Type }}" name="[{{ .Severity }}] {{ .ID }}" time="">
|
||||
{{- if (eq .Status "FAIL") }}
|
||||
<failure message="{{ escapeXML .Title }}" type="description">{{ escapeXML .Description }}</failure>
|
||||
{{- end }}
|
||||
</testcase>
|
||||
{{- end }}
|
||||
</testsuite>
|
||||
|
Loading…
Reference in New Issue
Block a user