#!groovy def repository = "registry.c.test-chamber-13.lan" def repositoryCreds = "harbor-repository-creds" def dockerFile = """FROM ${repository}/dockerhub/library/php:latest LABEL org.opencontainers.image.authors="The_Spider " COPY test-chamber-13.lan.root.crt /usr/local/share/ca-certificates/test-chamber-13.lan.root.crt RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y && apt-get clean && rm -rf /tmp/* /var/lib/apt/lists/* /var/tmp/* && docker-php-ext-install mysqli """ def label = "kubernetes-${UUID.randomUUID().toString()}" def templateName = "pipeline-worker" podTemplate( label: label, name: templateName, yaml: functions.podYaml( repo: repository, templateName: templateName, kaniko: true ) ) { node (label) { def workspace = pwd() writeFile(file: workspace + "/test-chamber-13.lan.root.crt", text: functions.getLocalRootCA()) functions.buildContainer( repository: repository, imageDest: "${repository}/library/php-mysqli:latest", dockerFile: dockerFile, repoCreds: repositoryCreds, ) } }