-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
1,285 additions
and
3,602 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,12 +2,12 @@ | |
FROM registry.cloudogu.com/official/java:8u362-1 as builder | ||
LABEL maintainer="[email protected]" \ | ||
NAME="official/nexus" \ | ||
VERSION="3.52.0-2" | ||
VERSION="3.59.0-1" | ||
|
||
WORKDIR /build | ||
|
||
# The version of nexus to install | ||
ENV NEXUS_VERSION=3.52.0-01 \ | ||
ENV NEXUS_VERSION=3.59.0-01 \ | ||
TINI_VERSION=0.19.0 \ | ||
NEXUS_CLAIM_VERSION=1.0.0 \ | ||
NEXUS_CARP_VERSION=1.3.1 \ | ||
|
@@ -16,7 +16,7 @@ ENV NEXUS_VERSION=3.52.0-01 \ | |
NEXUS_BUILD_DIR=/build/opt/sonatype/nexus \ | ||
BUILD_BIN_DIR=/build/usr/bin \ | ||
SHA256_TINI="c5b0666b4cb676901f90dfcb37106783c5fe2077b04590973b885950611b30ee" \ | ||
SHA256_NEXUS_TAR="f87766bb2ed606d5088c4059c8b804ddadfe2ff9403478b2d55441276b3af3a5" \ | ||
SHA256_NEXUS_TAR="19bc207fbf05e232d9c521e95cb7253e946a5e56521b828c4252a0b72f7262a8" \ | ||
SHA256_NEXUS_CLAIM="a34608ac7b516d6bc91f8a157bea286919c14e5fb5ecc76fc15edccb35adec42" \ | ||
SHA256_NEXUS_SCRIPTING="60c7f3d8a0c97b1d90d954ebad9dc07dbeb7927934b618c874b2e72295cafb48" \ | ||
SHA256_NEXUS_CARP="f9a9d9f9efcabd27fb4df2544142000d5607c8feb9772e77f23239d7a6647458" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
#!groovy | ||
@Library(['github.com/cloudogu/[email protected].0', 'github.com/cloudogu/dogu-build-lib@v2.1.0']) | ||
@Library(['github.com/cloudogu/[email protected].1', 'github.com/cloudogu/dogu-build-lib@v2.2.0']) | ||
import com.cloudogu.ces.cesbuildlib.* | ||
import com.cloudogu.ces.dogubuildlib.* | ||
|
||
|
@@ -73,7 +73,7 @@ node('vagrant') { | |
} | ||
|
||
stage('Integration Tests') { | ||
ecoSystem.runCypressIntegrationTests([cypressImage : "cypress/included:8.6.0", | ||
ecoSystem.runCypressIntegrationTests([cypressImage : "cypress/included:12.9.0", | ||
enableVideo : params.EnableVideoRecording, | ||
enableScreenshots: params.EnableScreenshotRecording]) | ||
} | ||
|
@@ -101,7 +101,7 @@ node('vagrant') { | |
|
||
stage('Integration Tests - After Upgrade') { | ||
ecoSystem.runCypressIntegrationTests([ | ||
cypressImage : "cypress/included:8.6.0", | ||
cypressImage : "cypress/included:12.9.0", | ||
enableVideo : params.EnableVideoRecording, | ||
enableScreenshots: params.EnableScreenshotRecording | ||
]) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
MAKEFILES_VERSION=7.6.0 | ||
VERSION=3.52.0-2 | ||
MAKEFILES_VERSION=7.10.0 | ||
VERSION=3.59.0-1 | ||
|
||
.DEFAULT_GOAL:=dogu-release | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ endif | |
## Variables | ||
|
||
BINARY_YQ = $(UTILITY_BIN_PATH)/yq | ||
BINARY_HELM = $(UTILITY_BIN_PATH)/helm | ||
|
||
# The productive tag of the image | ||
IMAGE ?= | ||
|
@@ -19,6 +20,8 @@ K3CES_REGISTRY_URL_PREFIX="${K3S_CLUSTER_FQDN}:${K3S_LOCAL_REGISTRY_PORT}" | |
# the current namespace and the dev image. | ||
K8S_RESOURCE_TEMP_FOLDER ?= $(TARGET_DIR)/make/k8s | ||
K8S_RESOURCE_TEMP_YAML ?= $(K8S_RESOURCE_TEMP_FOLDER)/$(ARTIFACT_ID)_$(VERSION).yaml | ||
K8S_HELM_TARGET ?= $(K8S_RESOURCE_TEMP_FOLDER)/helm | ||
K8S_HELM_RESSOURCES ?= k8s/helm | ||
|
||
##@ K8s - Variables | ||
|
||
|
@@ -75,6 +78,56 @@ k8s-apply: k8s-generate $(K8S_POST_GENERATE_TARGETS) ## Applies all generated K8 | |
@echo "Apply generated K8s resources..." | ||
@kubectl apply -f $(K8S_RESOURCE_TEMP_YAML) --namespace=${NAMESPACE} | ||
|
||
##@ K8s - Helm general | ||
|
||
${K8S_HELM_RESSOURCES}/Chart.yaml: ${BINARY_HELM} ## Creates the Chart.yaml-template if missing | ||
@echo "Create Chart.yaml..." | ||
@mkdir -p ${K8S_HELM_RESSOURCES}/tmp/ | ||
@${BINARY_HELM} create ${K8S_HELM_RESSOURCES}/tmp/${ARTIFACT_ID} | ||
@cp ${K8S_HELM_RESSOURCES}/tmp/${ARTIFACT_ID}/Chart.yaml ${K8S_HELM_RESSOURCES}/ | ||
@rm -dr ${K8S_HELM_RESSOURCES}/tmp | ||
@sed -i 's/appVersion: ".*"/appVersion: "0.0.0-replaceme"/' ${K8S_HELM_RESSOURCES}/Chart.yaml | ||
@sed -i 's/version: .*/version: 0.0.0-replaceme/' ${K8S_HELM_RESSOURCES}/Chart.yaml | ||
|
||
.PHONY: k8s-helm-delete | ||
k8s-helm-delete: ${BINARY_HELM} ## Uninstalls the current helm chart. | ||
@echo "Uninstall helm chart" | ||
@${BINARY_HELM} uninstall ${ARTIFACT_ID} | ||
|
||
.PHONY: k8s-helm-generate-chart | ||
k8s-helm-generate-chart: ${K8S_HELM_RESSOURCES}/Chart.yaml $(K8S_RESOURCE_TEMP_FOLDER) ## Generates the final helm chart. | ||
@echo "Generate helm chart..." | ||
@rm -drf ${K8S_HELM_TARGET} # delete folder, so Chart.yaml is newly created from template | ||
@mkdir -p ${K8S_HELM_TARGET}/templates | ||
@cp $(K8S_RESOURCE_TEMP_YAML) ${K8S_HELM_TARGET}/templates | ||
@cp ${K8S_HELM_RESSOURCES}/Chart.yaml ${K8S_HELM_TARGET} | ||
@sed -i 's/appVersion: "0.0.0-replaceme"/appVersion: "${VERSION}"/' ${K8S_HELM_TARGET}/Chart.yaml | ||
@sed -i 's/version: 0.0.0-replaceme/version: ${VERSION}/' ${K8S_HELM_TARGET}/Chart.yaml | ||
|
||
##@ K8s - Helm dev targets | ||
|
||
.PHONY: k8s-helm-generate | ||
k8s-helm-generate: k8s-generate k8s-helm-generate-chart ## Generates the final helm chart with dev-urls. | ||
|
||
.PHONY: k8s-helm-apply | ||
k8s-helm-apply: ${BINARY_HELM} image-import k8s-helm-generate $(K8S_POST_GENERATE_TARGETS) ## Generates and installs the helm chart. | ||
@echo "Apply generated helm chart" | ||
@${BINARY_HELM} upgrade -i ${ARTIFACT_ID} ${K8S_HELM_TARGET} | ||
|
||
.PHONY: k8s-helm-reinstall | ||
k8s-helm-reinstall: k8s-helm-delete k8s-helm-apply ## Uninstalls the current helm chart and reinstalls it. | ||
|
||
##@ K8s - Helm release targets | ||
|
||
.PHONY: k8s-helm-generate-release | ||
k8s-helm-generate-release: $(K8S_PRE_GENERATE_TARGETS) k8s-helm-generate-chart ## Generates the final helm chart with release urls. | ||
@sed -i "s/'{{ .Namespace }}'/'{{ .Release.Namespace }}'/" ${K8S_HELM_TARGET}/templates/$(ARTIFACT_ID)_$(VERSION).yaml | ||
|
||
.PHONY: k8s-helm-package-release | ||
k8s-helm-package-release: ${BINARY_HELM} k8s-helm-generate-release $(K8S_POST_GENERATE_TARGETS) ## Generates and packages the helm chart with release urls. | ||
@echo "Package generated helm chart" | ||
@${BINARY_HELM} package ${K8S_HELM_TARGET} -d ${K8S_HELM_TARGET} | ||
|
||
##@ K8s - Docker | ||
|
||
.PHONY: docker-build | ||
|
@@ -115,5 +168,8 @@ __check_defined = \ | |
$(if $(value $1),, \ | ||
$(error Undefined $1$(if $2, ($2)))) | ||
|
||
${BINARY_YQ}: $(UTILITY_BIN_PATH) ## Download controller-gen locally if necessary. | ||
$(call go-get-tool,$(BINARY_YQ),github.com/mikefarah/yq/[email protected]) | ||
${BINARY_YQ}: $(UTILITY_BIN_PATH) ## Download yq locally if necessary. | ||
$(call go-get-tool,$(BINARY_YQ),github.com/mikefarah/yq/[email protected]) | ||
|
||
${BINARY_HELM}: $(UTILITY_BIN_PATH) ## Download helm locally if necessary. | ||
$(call go-get-tool,$(BINARY_HELM),helm.sh/helm/v3/cmd/helm@latest) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
node_modules | ||
cypress/videos | ||
cypress/screenshots |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
const doguTestLibrary = require('@cloudogu/dogu-integration-test-library'); | ||
const { defineConfig } = require('cypress'); | ||
const createBundler = require("@bahmutov/cypress-esbuild-preprocessor"); | ||
const preprocessor = require("@badeball/cypress-cucumber-preprocessor"); | ||
const createEsbuildPlugin = require("@badeball/cypress-cucumber-preprocessor/esbuild"); | ||
|
||
async function setupNodeEvents(on, config) { | ||
// This is required for the preprocessor to be able to generate JSON reports after each run, and more, | ||
await preprocessor.addCucumberPreprocessorPlugin(on, config); | ||
|
||
on( | ||
"file:preprocessor", | ||
createBundler({ | ||
plugins: [createEsbuildPlugin.default(config)], | ||
}) | ||
); | ||
|
||
config = doguTestLibrary.configure(config); | ||
|
||
return config; | ||
} | ||
|
||
module.exports = defineConfig({ | ||
e2e: { | ||
baseUrl: 'https://192.168.56.2', | ||
env: { | ||
"DoguName": "nexus", | ||
"MaxLoginRetries": 3, | ||
"AdminUsername": "ces-admin", | ||
"AdminPassword": "ecosystem2016", | ||
"AdminGroup": "CesAdministrators" | ||
}, | ||
videoCompression: false, | ||
specPattern: ["cypress/e2e/**/*.feature"], | ||
setupNodeEvents, | ||
}, | ||
}); |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
9 changes: 7 additions & 2 deletions
9
integrationTests/cypress/support/step_definitions/dogu_integration_test_library_steps.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 0 additions & 46 deletions
46
integrationTests/cypress/support/step_definitions/nexus_gui.js
This file was deleted.
Oops, something went wrong.
18 changes: 9 additions & 9 deletions
18
...ess/support/step_definitions/nexus_api.js → .../cypress/support/step_definitions/then.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
const { | ||
When | ||
} = require("@badeball/cypress-cucumber-preprocessor"); | ||
|
||
|
||
When(/^the user clicks the logout button$/, function () { | ||
cy.get('#nx-header-signout-1144-btnEl').click(); | ||
}); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
{ | ||
"dependencies": { | ||
"cypress": "8.6.0", | ||
"cypress-cucumber-preprocessor": "4.1.0", | ||
"@cloudogu/dogu-integration-test-library": "1.0.0" | ||
"@badeball/cypress-cucumber-preprocessor": "^16.0.0", | ||
"@bahmutov/cypress-esbuild-preprocessor": "^2.2.0", | ||
"@cloudogu/dogu-integration-test-library": "6.0.1", | ||
"cypress": "^12.9.0", | ||
"@bahmutov/cy-api": "^2.2.4" | ||
}, | ||
"scripts": { | ||
"updateTests": "mkdir -p cypress/integration/dogu_integration_test_lib && cp -r node_modules/@cloudogu/dogu-integration-test-library/lib/integration/* cypress/integration/dogu_integration_test_lib" | ||
"updateTests": "mkdir -p cypress/e2e/dogu_integration_test_lib && cp -r node_modules/@cloudogu/dogu-integration-test-library/lib/integration/* cypress/e2e/dogu_integration_test_lib" | ||
} | ||
} |
Oops, something went wrong.