Skip to content

Commit d5300b4

Browse files
committed
fixes
1 parent 605e380 commit d5300b4

File tree

8 files changed

+11
-9
lines changed

8 files changed

+11
-9
lines changed

build-base-k8s-jenkins-agent.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,8 @@ docker build \
9696
-f k8s-jenkins-agent/Dockerfile \
9797
$last_arg
9898

99-
if [[ $PUSH_AGENT != "false" ]] ; then
99+
if [[ $PUSH_AGENT != "false" ]] && [[ -n "$DOCKER_REGISTRY_URL" ]]; then
100100
docker push $DOCKER_REGISTRY_URL/base-jenkins-agent:$ONEC_VERSION
101+
else
102+
echo "DOCKER_REGISTRY_URL not set or PUSH_AGENT is false, skipping docker push."
101103
fi

build-base-swarm-jenkins-agent.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,8 @@ docker build \
9696
-f swarm-jenkins-agent/Dockerfile \
9797
$last_arg
9898

99-
if [[ "$PUSH_AGENT" != "false" && -n "$DOCKER_REGISTRY_URL" ]]; then
99+
if [[ $PUSH_AGENT != "false" ]] && [[ -n "$DOCKER_REGISTRY_URL" ]]; then
100100
docker push "$DOCKER_REGISTRY_URL/base-jenkins-agent:$ONEC_VERSION"
101101
else
102-
echo "skipping docker push."
102+
echo "DOCKER_REGISTRY_URL not set or PUSH_AGENT is false, skipping docker push."
103103
fi

build-server.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ docker build \
3737
--build-arg DOCKER_REGISTRY_URL=$DOCKER_REGISTRY_URL \
3838
--build-arg BASE_IMAGE=oscript-downloader \
3939
--build-arg BASE_TAG=latest \
40-
-t ${DOCKER_REGISTRY_URL:+:"$DOCKER_REGISTRY_URL/"}onec-server:$ONEC_VERSION \
40+
-t ${DOCKER_REGISTRY_URL:+"$DOCKER_REGISTRY_URL/"}onec-server:$ONEC_VERSION \
4141
-f server/Dockerfile \
4242
$last_arg
4343

coverage41C/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG DOCKER_REGISTRY_URL=library
1+
ARG DOCKER_REGISTRY_URL
22
ARG BASE_IMAGE=edt
33
ARG BASE_TAG
44
ARG EDT_VERSION=2021.3

edt/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ARG DOWNLOADER_TAG
55

66
ARG BASE_IMAGE=eclipse-temurin
77
ARG BASE_TAG=11
8-
ARG DOCKER_REGISTRY_URL=library
8+
ARG DOCKER_REGISTRY_URL
99

1010
FROM ${DOWNLOADER_REGISTRY_URL:+"$DOWNLOADER_REGISTRY_URL/"}${DOWNLOADER_IMAGE}:${DOWNLOADER_TAG} AS downloader
1111

executor/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG DOCKER_REGISTRY_URL=library
1+
ARG DOCKER_REGISTRY_URL
22
ARG BASE_IMAGE=ubuntu
33
ARG BASE_TAG=24.04
44
FROM ${DOCKER_REGISTRY_URL:+"$DOCKER_REGISTRY_URL/"}${BASE_IMAGE}:${BASE_TAG}

jdk/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG DOCKER_REGISTRY_URL=library
1+
ARG DOCKER_REGISTRY_URL
22
ARG BASE_IMAGE=debian
33
ARG BASE_TAG=bookworm-slim
44

oscript/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG DOCKER_REGISTRY_URL=""
1+
ARG DOCKER_REGISTRY_URL
22
ARG BASE_IMAGE=debian
33
ARG BASE_TAG=bookworm-slim
44

0 commit comments

Comments
 (0)