Skip to content

Commit 8e930f4

Browse files
Marco Bergencesmarvin
Marco Bergen
authored andcommitted
Merge branch 'release/v1.7.7-1'
2 parents 1e8ba81 + 3e179bf commit 8e930f4

28 files changed

+437
-89
lines changed

CHANGELOG.md

+8
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [v1.7.7-1] - 2025-03-13
11+
### Changed
12+
- [#240] Change error pages to show the new design
13+
- [#240] Remove ticket query param if invalid instead of showing an error page
14+
- Update makefiles to 9.6.0
15+
- Update ces-build-lib to 4.1.0
16+
- Update dogu-build-lib to 3.1.0
17+
1018
## [v1.7.6-2] - 2025-02-12
1119
### Changed
1220
- [#238] Add missing keys to dogu.json

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ RUN set -x \
1818

1919
FROM registry.cloudogu.com/official/java:21.0.5-1
2020
LABEL NAME="official/smeagol" \
21-
VERSION="1.7.6-2" \
21+
VERSION="1.7.7-1" \
2222
maintainer="[email protected]"
2323

2424
ENV SERVICE_TAGS=webapp \

Jenkinsfile

+9-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!groovy
2-
@Library(['github.com/cloudogu/ces-build-lib@2.2.1', 'github.com/cloudogu/dogu-build-lib@v2.3.1'])
2+
@Library(['github.com/cloudogu/ces-build-lib@4.1.0', 'github.com/cloudogu/dogu-build-lib@v3.1.0'])
33
import com.cloudogu.ces.cesbuildlib.*
44
import com.cloudogu.ces.dogubuildlib.*
55

@@ -15,7 +15,6 @@ GitHub github = new GitHub(this, git)
1515
Changelog changelog = new Changelog(this)
1616

1717
EcoSystem ecoSystem = new EcoSystem(this, "gcloud-ces-operations-internal-packer", "jenkins-gcloud-ces-operations-internal")
18-
Trivy trivy = new Trivy(this, ecoSystem)
1918

2019
parallel(
2120
"source code": {
@@ -112,6 +111,8 @@ parallel(
112111
booleanParam(defaultValue: true, description: 'Enables cypress to take screenshots of failing integration tests.', name: 'EnableScreenshotRecording'),
113112
booleanParam(defaultValue: false, description: 'Test dogu upgrade from latest release or optionally from defined version below', name: 'TestDoguUpgrade'),
114113
string(defaultValue: '', description: 'Old Dogu version for the upgrade test (optional; e.g. 2.222.1-1)', name: 'OldDoguVersionForUpgradeTest'),
114+
choice(name: 'TrivySeverityLevels', choices: [TrivySeverityLevel.CRITICAL, TrivySeverityLevel.HIGH_AND_ABOVE, TrivySeverityLevel.MEDIUM_AND_ABOVE, TrivySeverityLevel.ALL], description: 'The levels to scan with trivy', defaultValue: TrivySeverityLevel.CRITICAL),
115+
choice(name: 'TrivyStrategy', choices: [TrivyScanStrategy.UNSTABLE, TrivyScanStrategy.FAIL, TrivyScanStrategy.IGNORE], description: 'Define whether the build should be unstable, fail or whether the error should be ignored if any vulnerability was found.', defaultValue: TrivyScanStrategy.UNSTABLE)
115116
])
116117
])
117118

@@ -143,9 +144,12 @@ parallel(
143144
}
144145

145146
stage('Trivy scan') {
146-
trivy.scanDogu("/dogu", TrivyScanFormat.HTML, TrivyScanLevel.CRITICAL, TrivyScanStrategy.UNSTABLE)
147-
trivy.scanDogu("/dogu", TrivyScanFormat.JSON, TrivyScanLevel.CRITICAL, TrivyScanStrategy.UNSTABLE)
148-
trivy.scanDogu("/dogu", TrivyScanFormat.PLAIN, TrivyScanLevel.CRITICAL, TrivyScanStrategy.UNSTABLE)
147+
ecoSystem.copyDoguImageToJenkinsWorker("/dogu")
148+
Trivy trivy = new Trivy(this)
149+
trivy.scanDogu(".", params.TrivySeverityLevels, params.TrivyStrategy)
150+
trivy.saveFormattedTrivyReport(TrivyScanFormat.TABLE)
151+
trivy.saveFormattedTrivyReport(TrivyScanFormat.JSON)
152+
trivy.saveFormattedTrivyReport(TrivyScanFormat.HTML)
149153
}
150154

151155
stage('Verify') {

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
MAKEFILES_VERSION=9.5.0
1+
MAKEFILES_VERSION=9.6.0
22

33
.DEFAULT_GOAL:=dogu-release
44

build/make/k8s.mk

+3-3
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,11 @@ K3S_LOCAL_REGISTRY_PORT?=30099
3636

3737
# The URL of the container-registry to use. Defaults to the registry of the local-cluster.
3838
# If RUNTIME_ENV is "remote" it is "registry.cloudogu.com/testing"
39-
CES_REGISTRY_HOST?="${K3S_CLUSTER_FQDN}:${K3S_LOCAL_REGISTRY_PORT}"
39+
CES_REGISTRY_HOST?=${K3S_CLUSTER_FQDN}:${K3S_LOCAL_REGISTRY_PORT}
4040
CES_REGISTRY_NAMESPACE ?=
4141
ifeq (${RUNTIME_ENV}, remote)
42-
CES_REGISTRY_HOST="registry.cloudogu.com"
43-
CES_REGISTRY_NAMESPACE="/testing"
42+
CES_REGISTRY_HOST=registry.cloudogu.com
43+
CES_REGISTRY_NAMESPACE=/testing
4444
endif
4545
$(info CES_REGISTRY_HOST=$(CES_REGISTRY_HOST))
4646

build/make/prerelease.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33

44
.PHONY: prerelease_namespace
55
prerelease_namespace:
6-
build/make/stagex.sh prerelease_namespace
6+
build/make/prerelease.sh prerelease_namespace

build/make/prerelease.sh

100644100755
+10-2
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,29 @@ set -o pipefail
55

66
prerelease_namespace() {
77

8+
TIMESTAMP=$(date +"%Y%m%d%H%M%S")
9+
810
# Update version in dogu.json
911
if [ -f "dogu.json" ]; then
1012
echo "Updating name in dogu.json..."
1113
ORIG_NAME="$(jq -r ".Name" ./dogu.json)"
14+
ORIG_VERSION="$(jq -r ".Version" ./dogu.json)"
1215
PRERELEASE_NAME="prerelease_${ORIG_NAME}"
16+
PRERELEASE_VERSION="${ORIG_VERSION}${TIMESTAMP}"
1317
jq ".Name = \"${PRERELEASE_NAME}\"" dogu.json >dogu2.json && mv dogu2.json dogu.json
18+
jq ".Version = \"${PRERELEASE_VERSION}\"" dogu.json >dogu2.json && mv dogu2.json dogu.json
1419
jq ".Image = \"registry.cloudogu.com/${PRERELEASE_NAME}\"" dogu.json >dogu2.json && mv dogu2.json dogu.json
1520
fi
1621

1722
# Update version in Dockerfile
1823
if [ -f "Dockerfile" ]; then
1924
echo "Updating version in Dockerfile..."
20-
ORIG_NAME="$(grep -oP "^[ ]*NAME=\"([^\"]*)" Dockerfile | awk -F "\"" '{print $2}')"
25+
ORIG_NAME="$(grep -oP ".*[ ]*NAME=\"([^\"]*)" Dockerfile | awk -F "\"" '{print $2}')"
26+
ORIG_VERSION="$(grep -oP ".*[ ]*VERSION=\"([^\"]*)" Dockerfile | awk -F "\"" '{print $2}')"
2127
PRERELEASE_NAME="prerelease_$( echo -e "$ORIG_NAME" | sed 's/\//\\\//g' )"
22-
sed -i "s/\(^[ ]*NAME=\"\)\([^\"]*\)\(.*$\)/\1${PRERELEASE_NAME}\3/" Dockerfile
28+
PRERELEASE_VERSION="${ORIG_VERSION}${TIMESTAMP}"
29+
sed -i "s/\(.*[ ]*NAME=\"\)\([^\"]*\)\(.*$\)/\1${PRERELEASE_NAME}\3/" Dockerfile
30+
sed -i "s/\(.*[ ]*VERSION=\"\)\([^\"]*\)\(.*$\)/\1${PRERELEASE_VERSION}\3/" Dockerfile
2331
fi
2432

2533
}

build/make/release.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
.PHONY: dogu-release
66
dogu-release: ## Start a dogu release
7-
build/make/release.sh dogu
7+
build/make/release.sh dogu "${FIXED_CVE_LIST}" $(DRY_RUN)
88

99
.PHONY: node-release
1010
node-release: ## Start a node package release

build/make/self-update.mk

+6-1
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,9 @@ copy-new-files:
2424
.PHONY: update-build-libs
2525
update-build-libs:
2626
@echo "Check for newer Build-Lib versions"
27-
build/make/self-update.sh buildlibs
27+
build/make/self-update.sh buildlibs
28+
29+
.PHONY: set-dogu-version
30+
set-dogu-version:
31+
@echo "Set Version of Dogu without Release"
32+
build/make/self-update.sh versions

build/make/self-update.sh

+16-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ set -o errexit
33
set -o nounset
44
set -o pipefail
55

6+
7+
# shellcheck disable=SC1090
8+
source "$(pwd)/build/make/release_functions.sh"
9+
610
TYPE="${1}"
711

812
update_build_libs() {
@@ -34,12 +38,23 @@ get_highest_version() {
3438
# Patch Jenkinsfile
3539
update_jenkinsfile() {
3640
sed -i "s/ces-build-lib@[[:digit:]].[[:digit:]].[[:digit:]]/ces-build-lib@$(get_highest_version ces)/g" Jenkinsfile
37-
sed -i "s/dugu-build-lib@[[:digit:]].[[:digit:]].[[:digit:]]/dogu-build-lib@$(get_highest_version dogu)/g" Jenkinsfile
41+
sed -i "s/dogu-build-lib@v[[:digit:]].[[:digit:]].[[:digit:]]/dogu-build-lib@v$(get_highest_version dogu)/g" Jenkinsfile
42+
}
43+
44+
# Patch Dogu Version without Release
45+
set_dogu_version() {
46+
CURRENT_TOOL_VERSION=$(get_current_version_by_dogu_json)
47+
echo "$(tput setaf 1)ATTENTION: Make sure that the new version corresponds to the current software version$(tput sgr0)"
48+
NEW_RELEASE_VERSION="$(read_new_version)"
49+
validate_new_version "${NEW_RELEASE_VERSION}"
50+
update_versions "${NEW_RELEASE_VERSION}"
3851
}
3952

4053
# switch for script entrypoint
4154
if [[ "${TYPE}" == "buildlibs" ]];then
4255
update_build_libs
56+
elif [[ "${TYPE}" == "versions" ]];then
57+
set_dogu_version
4358
else
4459
echo "Unknown target ${TYPE}"
4560
fi

build/make/test-common.mk

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
GO_JUNIT_REPORT=$(UTILITY_BIN_PATH)/go-junit-report
2-
GO_JUNIT_REPORT_VERSION=v1.0.0
2+
GO_JUNIT_REPORT_VERSION=v2.1.0
33

44
$(GO_JUNIT_REPORT): $(UTILITY_BIN_PATH)
55
@echo "Download go-junit-report..."
6-
@$(call go-get-tool,$@,github.com/jstemmer/go-junit-report@$(GO_JUNIT_REPORT_VERSION))
6+
@$(call go-get-tool,$@,github.com/jstemmer/go-junit-report/v2@$(GO_JUNIT_REPORT_VERSION))

build/make/test-unit.mk

+7-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
##@ Unit testing
22

33
UNIT_TEST_DIR=$(TARGET_DIR)/unit-tests
4+
XUNIT_JSON=$(UNIT_TEST_DIR)/report.json
45
XUNIT_XML=$(UNIT_TEST_DIR)/unit-tests.xml
56
UNIT_TEST_LOG=$(UNIT_TEST_DIR)/unit-tests.log
67
COVERAGE_REPORT=$(UNIT_TEST_DIR)/coverage.out
@@ -9,9 +10,9 @@ PRE_UNITTESTS?=
910
POST_UNITTESTS?=
1011

1112
.PHONY: unit-test
12-
unit-test: $(XUNIT_XML) ## Start unit tests
13+
unit-test: $(XUNIT_JSON) ## Start unit tests
1314

14-
$(XUNIT_XML): $(SRC) $(GO_JUNIT_REPORT)
15+
$(XUNIT_JSON): $(SRC) $(GO_JUNIT_REPORT)
1516
ifneq ($(strip $(PRE_UNITTESTS)),)
1617
@make $(PRE_UNITTESTS)
1718
endif
@@ -20,13 +21,15 @@ endif
2021
@echo 'mode: set' > ${COVERAGE_REPORT}
2122
@rm -f $(UNIT_TEST_LOG) || true
2223
@for PKG in $(PACKAGES) ; do \
23-
${GO_CALL} test -v $$PKG -coverprofile=${COVERAGE_REPORT}.tmp 2>&1 | tee $(UNIT_TEST_LOG).tmp ; \
24+
${GO_CALL} test -v $$PKG -coverprofile=${COVERAGE_REPORT}.tmp -json 2>&1 | tee $(UNIT_TEST_LOG).tmp ; \
2425
cat ${COVERAGE_REPORT}.tmp | tail +2 >> ${COVERAGE_REPORT} ; \
2526
rm -f ${COVERAGE_REPORT}.tmp ; \
2627
cat $(UNIT_TEST_LOG).tmp >> $(UNIT_TEST_LOG) ; \
2728
rm -f $(UNIT_TEST_LOG).tmp ; \
2829
done
29-
@cat $(UNIT_TEST_LOG) | $(GO_JUNIT_REPORT) > $@
30+
@cat $(UNIT_TEST_LOG) >> $@
31+
@cat $(UNIT_TEST_LOG) | $(GO_JUNIT_REPORT) -parser gojson > $(XUNIT_XML)
32+
3033
@if grep '^FAIL' $(UNIT_TEST_LOG); then \
3134
exit 1; \
3235
fi

docs/gui/release_notes_de.md

+5
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ Technische Details zu einem Release finden Sie im zugehörigen [Changelog](https
66

77
## [Unreleased]
88

9+
## [v1.7.7-1] - 2025-03-13
10+
11+
- Das Design der Fehlerseiten wurde überarbeitet
12+
- Es wurde ein Fehler behoben, der aufgetreten ist, wenn ein ungültiges CAS-Service-Ticket verwendet wurde
13+
914
## [v1.7.6-2] - 2025-02-12
1015

1116
Wir haben nur technische Änderungen vorgenommen. Näheres finden Sie in den Changelogs.

docs/gui/release_notes_en.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,15 @@ Technical details on a release can be found in the corresponding [Changelog](htt
66

77
## [Unreleased]
88

9+
## [v1.7.7-1] - 2025-03-13
10+
11+
- The design of the error pages has been revised
12+
- Fixed an error that occurred when an invalid CAS service ticket was used
13+
914
## [v1.7.6-2] - 2025-02-12
1015

1116
We have only made technical changes. You can find more details in the changelogs.
1217

13-
1418
## [v1.7.6-1] - 2025-01-10
1519
**The release fixes a critical security vulnerability ([CVE-2024-56337](https://github.com/advisories/GHSA-27hp-xhwr-wr2m)). An update is therefore recommended.**
1620

dogu.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"Name": "official/smeagol",
3-
"Version": "1.7.6-2",
3+
"Version": "1.7.7-1",
44
"DisplayName": "Smeagol",
55
"Description": "Store your technical documentation with in your git repositories",
66
"Category": "Development Apps",

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "smeagol",
3-
"version": "1.7.6-2",
3+
"version": "1.7.7-1",
44
"private": true,
55
"license": "AGPL-3.0-only",
66
"dependencies": {

pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
<groupId>com.cloudogu.wiki</groupId>
1414
<artifactId>smeagol</artifactId>
15-
<version>1.7.6-2</version>
15+
<version>1.7.7-1</version>
1616
<name>smeagol</name>
1717
<packaging>war</packaging>
1818

resources/app/application.yml.tpl

+2
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ scm:
88
cas:
99
url: https://{{ .Env.Get "FQDN" }}/cas
1010
serviceUrl: https://{{ .Env.Get "FQDN" }}
11+
errors:
12+
url: https://{{ .Env.Get "FQDN" }}/errors/

0 commit comments

Comments
 (0)