Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates for WLP 23.0.0.12 #55

Merged
merged 1 commit into from
Dec 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 22 additions & 22 deletions .one-pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ setup:
#!/usr/bin/env bash

set_env S2I_URI "https://api.github.com/repos/openshift/source-to-image/releases/tags/v1.3.9"
set_env CEKIT_VERSION "4.8.0"
set_env LIBERTY_VERSION "23.0.0.11"
set_env CEKIT_VERSION "4.8.0"
set_env LIBERTY_VERSION "23.0.0.12"

test:
abort_on_failure: false
Expand All @@ -29,7 +29,7 @@ static-scan:
image: icr.io/continuous-delivery/pipeline/pipeline-base-image:2.12@sha256:ff4053b0bca784d6d105fee1d008cfb20db206011453071e86b69ca3fde706a4
script: |
#!/usr/bin/env bash
# scan for open liberty and websphere liberty submodules?
# scan for open liberty and websphere liberty submodules?
PERIODIC_SCAN=$(get_env periodic-rescan)
PERIODIC_SCAN="$(echo "$PERIODIC_SCAN" | tr '[:upper:]' '[:lower:]')"

Expand All @@ -40,8 +40,8 @@ static-scan:
read -r SONAR_HOST_URL <<< "$(get_env sonarqube | jq -r '.parameters.dashboard_url' | sed 's:/*$::')"
read -r SONAR_USER <<< "$(get_env sonarqube | jq -r '.parameters.user_login')"
SONARQUBE_INSTANCE_ID=$(get_env sonarqube | jq -r '.instance_id')
read -r SONAR_PASS <<< "$(jq -r --arg sonar_instance "$SONARQUBE_INSTANCE_ID" '[.services[] | select(."service_id"=="sonarqube")][] | select(."instance_id"==$sonar_instance) | .parameters.user_password' /toolchain/toolchain.json)"
touch "$WORKSPACE"/websphere-liberty-s2i/sonar-project.properties
read -r SONAR_PASS <<< "$(jq -r --arg sonar_instance "$SONARQUBE_INSTANCE_ID" '[.services[] | select(."service_id"=="sonarqube")][] | select(."instance_id"==$sonar_instance) | .parameters.user_password' /toolchain/toolchain.json)"
touch "$WORKSPACE"/websphere-liberty-s2i/sonar-project.properties
cat << EOF > "$WORKSPACE"/websphere-liberty-s2i/sonar-project.properties
sonar.projectKey=liberty-eks-aws
sonar.host.url=$SONAR_HOST_URL
Expand Down Expand Up @@ -77,15 +77,15 @@ containerize:
echo "Skipping build. This is a periodic run that is only meant to produce CVE information."
exit 0
else
if [[ "$PIPELINE_DEBUG" == 1 ]]; then
if [[ "$PIPELINE_DEBUG" == 1 ]]; then
trap env EXIT
env
set -x
fi
fi

dnf -y install python3-devel krb5-devel
# Download cekit
# Download cekit
CEKIT_VERSION=$(get_env CEKIT_VERSION)
pip3 install virtualenv
mkdir ~/cekit${CEKIT_VERSION}
Expand Down Expand Up @@ -117,9 +117,9 @@ containerize:
echo "***** Installed S2I *****"
s2i version
cd -

echo "${PIPELINE_PASSWORD}" | docker login "${PIPELINE_REGISTRY}" -u "${PIPELINE_USERNAME}" --password-stdin

echo "***** Running Tests *****"
make -e test PROD_NAMESPACE=cp/olc

Expand All @@ -131,47 +131,47 @@ containerize:
fi

echo "***** Available Docker Images *****"
docker image ls
docker image ls

LIBERTY_VERSION=$(get_env LIBERTY_VERSION)
JAVA8_IMAGE_VERSION=${LIBERTY_VERSION}-java8
JAVA8_RUNTIME_IMAGE_VERSION=${LIBERTY_VERSION}-runtime-java8
JAVA11_IMAGE_VERSION=${LIBERTY_VERSION}-java11
JAVA11_RUNTIME_IMAGE_VERSION=${LIBERTY_VERSION}-runtime-java11
JAVA17_IMAGE_VERSION=${LIBERTY_VERSION}-java17
JAVA17_RUNTIME_IMAGE_VERSION=${LIBERTY_VERSION}-runtime-java17
JAVA17_RUNTIME_IMAGE_VERSION=${LIBERTY_VERSION}-runtime-java17
NAMESPACE=cp/olc
PLATFORM=websphere-liberty-s2i
IMAGE_NAME=${NAMESPACE}/${PLATFORM}

echo Pushing the following versions of image ${IMAGE_NAME} to ${PIPELINE_REGISTRY}:
echo ${JAVA8_IMAGE_VERSION}, ${JAVA8_RUNTIME_IMAGE_VERSION}, ${JAVA11_IMAGE_VERSION}, ${JAVA11_RUNTIME_IMAGE_VERSION}, ${JAVA17_IMAGE_VERSION}, ${JAVA17_RUNTIME_IMAGE_VERSION}

docker tag ${IMAGE_NAME}:${JAVA8_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA8_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA8_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA8_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java8
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java8

docker tag ${IMAGE_NAME}:${JAVA8_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA8_RUNTIME_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA8_RUNTIME_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA8_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:runtime-java8
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:runtime-java8

docker tag ${IMAGE_NAME}:${JAVA11_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA11_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA11_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA11_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java11
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java11

docker tag ${IMAGE_NAME}:${JAVA11_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA11_RUNTIME_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA11_RUNTIME_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA11_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:runtime-java11
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:runtime-java11

docker tag ${IMAGE_NAME}:${JAVA17_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA17_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA17_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA17_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java17
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:java17

docker tag ${IMAGE_NAME}:${JAVA17_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA17_RUNTIME_IMAGE_VERSION}
docker push ${PIPELINE_REGISTRY}/${IMAGE_NAME}:${JAVA17_RUNTIME_IMAGE_VERSION}
docker tag ${IMAGE_NAME}:${JAVA17_RUNTIME_IMAGE_VERSION} ${PIPELINE_REGISTRY}/${IMAGE_NAME}:runtime-java17
Expand All @@ -182,7 +182,7 @@ containerize:
for i in "${tags[@]}"
do
IMAGE=$PIPELINE_REGISTRY/$NAMESPACE/$PIPELINE_S2I_IMAGE:$i
DIGEST="$(skopeo inspect docker://$IMAGE | grep Digest | grep -o 'sha[^\"]*')"
DIGEST="$(skopeo inspect docker://$IMAGE | grep Digest | grep -o 'sha[^\"]*')"
echo "Saving artifact s2i-$i name=$IMAGE digest=$DIGEST type=$TYPE"
save_artifact s2i-$i type="image" name="$IMAGE" "digest=$DIGEST" arch="amd64"
done
Expand All @@ -201,8 +201,8 @@ containerize:
source "${COMMONS_PATH}/whitesource/whitesource_unified_agent_scan.sh"




sign-artifact:
abort_on_failure: false
image: icr.io/continuous-delivery/pipeline/image-signing:1.0.0@sha256:e9d8e354668ba3d40be2aaee08298d2aa7f0e1c8a1829cca4094ec93830e3e6a
Expand Down Expand Up @@ -261,7 +261,7 @@ acceptance-test:
echo "Skipping unit-tests. This is a periodic run that is only meant to produce CVE information."
exit 0
fi

scan-artifact:
abort_on_failure: false
image: icr.io/continuous-delivery/pipeline/pipeline-base-image:2.15
Expand Down Expand Up @@ -294,7 +294,7 @@ release:
fi
SKIP_ALL_CHECKS=$(get_env SKIP_ALL_CHECKS "false")
echo "**** Running Evaluator ****"
./pipeline/evaluator.sh
./pipeline/evaluator.sh
if [[ $? == 0 || $SKIP_ALL_CHECKS == "true" ]]; then
if [[ $SKIP_ALL_CHECKS == "true" ]]; then
echo "Skipping image scan checks"
Expand Down
7 changes: 3 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LIBERTY_VERSION=23.0.0.11
LIBERTY_VERSION=23.0.0.12
JAVA8_IMAGE_VERSION=$(LIBERTY_VERSION)-java8
JAVA8_RUNTIME_IMAGE_VERSION=$(LIBERTY_VERSION)-runtime-java8
JAVA11_IMAGE_VERSION=$(LIBERTY_VERSION)-java11
Expand All @@ -10,7 +10,7 @@ PROD_NAMESPACE?=ibmcom
PLATFORM=websphere-liberty-s2i
IMAGE_NAME=${NAMESPACE}/${PLATFORM}
BUILD_IMAGE_NAME=${PROD_NAMESPACE}/${PLATFORM}
DOCKER_HOST=tcp://localhost:2376


build = ./build.sh

Expand All @@ -24,7 +24,7 @@ script_env = \
JAVA11_IMAGE_VERSION=$(JAVA11_IMAGE_VERSION) \
JAVA11_RUNTIME_IMAGE_VERSION=$(JAVA11_RUNTIME_IMAGE_VERSION) \
JAVA17_IMAGE_VERSION=$(JAVA17_IMAGE_VERSION) \
JAVA17_RUNTIME_IMAGE_VERSION=$(JAVA17_RUNTIME_IMAGE_VERSION)
JAVA17_RUNTIME_IMAGE_VERSION=$(JAVA17_RUNTIME_IMAGE_VERSION)

.PHONY: build
build:
Expand All @@ -33,4 +33,3 @@ build:
.PHONY: test
test:
$(script_env) TEST_MODE=true $(build)

Loading