Skip to content

Commit 67f5a20

Browse files
authored
Consolidate the onepipeline test scripts into a common repo (#547)
* Move pipeline cluster scripts to common repo * Use consolidated test scripts * Update acceptane stage in .one-pipeline.yaml * minor update to .one-pipeline.yaml * Move ocp-cluster-e2e.sh to common repo * Remove the scripts that have been moved tothe common repo * Copy configure cluster scripts * update acceptance stage of .one-pipeline.yaml
1 parent c3dbbc0 commit 67f5a20

File tree

11 files changed

+5
-1608
lines changed

11 files changed

+5
-1608
lines changed

.one-pipeline.yaml

Lines changed: 3 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ setup:
1010
1111
cp operators/scripts/pipeline/* ./scripts/pipeline/
1212
cp -rf operators/scripts/build ./scripts/
13+
cp -rf operators/scripts/configure-cluster ./scripts
14+
cp -rf operators/scripts/test ./scripts/
1315
1416
./scripts/pipeline/code-setup-stage.sh
1517
@@ -121,39 +123,7 @@ acceptance-test:
121123
#!/usr/bin/env bash
122124
echo $STAGE
123125
124-
PERIODIC_SCAN=$(get_env periodic-rescan)
125-
PERIODIC_SCAN="$(echo "$PERIODIC_SCAN" | tr '[:upper:]' '[:lower:]')"
126-
127-
if [[ ! -z "$PERIODIC_SCAN" && "$PERIODIC_SCAN" != "false" && "$PERIODIC_SCAN" != "no" ]]; then
128-
echo "Skipping acceptance-test. This is a periodic run that is only meant to produce CVE information."
129-
exit 0
130-
fi
131-
132-
SKIP_ACCEPTANCE_TEST=$(get_env SKIP_ACCEPTANCE_TEST)
133-
SKIP_ACCEPTANCE_TEST="$(echo "$SKIP_ACCEPTANCE_TEST" | tr '[:upper:]' '[:lower:]')"
134-
if [[ ! -z "$SKIP_ACCEPTANCE_TEST" && "$SKIP_ACCEPTANCE_TEST" != "false" && "$SKIP_ACCEPTANCE_TEST" != "no" ]]; then
135-
echo "Skipping acceptance-test, SKIP_ACCEPTANCE_TEST=$SKIP_ACCEPTANCE_TEST"
136-
exit 0
137-
fi
138-
139-
export intranetId_USR=$(get_env ebc_id)
140-
export intranetId_PSW=$(get_env ebc_pw)
141-
export ebcEnvironment=prod
142-
143-
cd scripts/pipeline
144-
rm -rf .git
145-
git clone https://$(get_env git-token)@github.ibm.com/elastic-build-cloud/ebc-gateway-http.git
146-
147-
export arch=$(get_env architecture)
148-
export test_arch=$(get_env test-architecture)
149-
150-
if [[ "$test_arch" == "ZXP" && "$arch" == "ZXP" ]]; then
151-
source runTest.sh Z
152-
source runTest.sh X
153-
source runTest.sh P
154-
else
155-
source runTest.sh X
156-
fi
126+
./scripts/pipeline/acceptance-test-stage.sh
157127
158128
scan-artifact:
159129
abort_on_failure: false

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ catalog-build: opm ## Build a catalog image.
333333
$(OPM) index add $(SKIP_TLS_VERIFY) --container-tool $(CONTAINER_COMMAND) --mode semver --tag $(CATALOG_IMG) --bundles $(BUNDLE_IMGS) $(FROM_INDEX_OPT) --permissive
334334

335335
kind-e2e-test:
336-
./scripts/e2e-kind.sh --test-tag "${TRAVIS_BUILD_NUMBER}"
336+
./scripts/test/e2e-kind.sh --test-tag "${TRAVIS_BUILD_NUMBER}"
337337

338338
build-manifest: setup-manifest
339339
./scripts/build/build-manifest.sh --registry "${PUBLISH_REGISTRY}" --image "${OPERATOR_IMAGE}" --tag "${RELEASE_TARGET}"
@@ -355,7 +355,7 @@ test-e2e:
355355
--test-tag "${TRAVIS_BUILD_NUMBER}" --target "${RELEASE_TARGET}"
356356

357357
test-pipeline-e2e:
358-
./scripts/pipeline/ocp-cluster-e2e.sh -u "${DOCKER_USERNAME}" -p "${DOCKER_PASSWORD}" \
358+
./scripts/test/e2e-ocp.sh -u "${DOCKER_USERNAME}" -p "${DOCKER_PASSWORD}" \
359359
--cluster-url "${CLUSTER_URL}" --cluster-user "${CLUSTER_USER}" --cluster-token "${CLUSTER_TOKEN}" \
360360
--registry-name "${PIPELINE_REGISTRY}" --registry-image "${PIPELINE_OPERATOR_IMAGE}" \
361361
--registry-user "${PIPELINE_USERNAME}" --registry-password "${PIPELINE_PASSWORD}" \

scripts/create-fyre-stack.sh

Lines changed: 0 additions & 163 deletions
This file was deleted.

scripts/delete-fyre-stack.sh

Lines changed: 0 additions & 53 deletions
This file was deleted.

0 commit comments

Comments
 (0)