Compare commits
No commits in common. "develop" and "master" have entirely different histories.
@ -4,7 +4,7 @@ steps:
|
||||
image: woodpeckerci/plugin-kaniko
|
||||
settings:
|
||||
registry: harbor.dvirlabs.com
|
||||
repo: dev-tools/wp-kaniko-sync
|
||||
repo: devtools/wp-kaniko-sync
|
||||
dockerfile: Dockerfile
|
||||
context: .
|
||||
tags:
|
||||
|
||||
26
Dockerfile
26
Dockerfile
@ -1,26 +1,14 @@
|
||||
# שלב 1: בניית כלים
|
||||
FROM alpine:3.19 as builder
|
||||
FROM alpine:3.19
|
||||
|
||||
# כלים: git, yq, curl לבניית Kaniko
|
||||
RUN apk add --no-cache bash git yq curl
|
||||
|
||||
# הורדת Kaniko בינארי
|
||||
RUN curl -sSL -o /kaniko \
|
||||
https://github.com/GoogleContainerTools/kaniko/releases/download/v1.20.1/executor && \
|
||||
chmod +x /kaniko
|
||||
# התקנת Kaniko
|
||||
RUN mkdir -p /kaniko && \
|
||||
curl -sSL -o /kaniko/executor https://github.com/GoogleContainerTools/kaniko/releases/download/v1.21.0/executor && \
|
||||
chmod +x /kaniko/executor
|
||||
|
||||
# שלב 2: בניית פלאגין סופי על בסיס woodpeckerci/plugin-kaniko
|
||||
FROM woodpeckerci/plugin-kaniko:latest
|
||||
|
||||
USER root
|
||||
|
||||
# העתקת הכלים מה-builder
|
||||
COPY --from=builder /kaniko /usr/local/bin/kaniko
|
||||
COPY --from=builder /bin/bash /bin/bash
|
||||
COPY --from=builder /usr/bin/git /usr/bin/git
|
||||
COPY --from=builder /usr/bin/yq /usr/bin/yq
|
||||
COPY --from=builder /usr/bin/curl /usr/bin/curl
|
||||
|
||||
ENV PATH="/usr/local/bin:$PATH"
|
||||
ENV PATH="/kaniko:$PATH"
|
||||
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
@ -7,7 +7,7 @@ TAG="${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:7}"
|
||||
echo "🧩 Using tag: $TAG"
|
||||
|
||||
echo "🔨 Building Docker image for ${PLUGIN_CONTEXT}"
|
||||
kaniko \
|
||||
/kaniko/executor \
|
||||
--dockerfile="${PLUGIN_DOCKERFILE}" \
|
||||
--context="${PLUGIN_CONTEXT}" \
|
||||
--destination="${PLUGIN_REGISTRY}/${PLUGIN_REPO}:${TAG}" \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user