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

Nexus: Set ingress paths as templated values #515

Closed
wants to merge 1 commit into from
Closed
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
6 changes: 6 additions & 0 deletions charts/nexus3/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Deprecated
### Removed -->

## [v4.14.2] - 2022-09-21

### Changed

- Set ingress path as templated value

## [v4.14.1] - 2022-08-22

### Changed
Expand Down
2 changes: 1 addition & 1 deletion charts/nexus3/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: nexus3
description: Helm chart for Sonatype Nexus 3 OSS.
type: application
version: 4.14.1
version: 4.14.2
appVersion: 3.41.1
home: https://www.sonatype.com/nexus-repository-oss
icon: https://help.sonatype.com/docs/files/331022/34537964/3/1564671303641/NexusRepo_Icon.png
Expand Down
2 changes: 1 addition & 1 deletion charts/nexus3/files/configure.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -eu

nexus_host="http://localhost:8081"
nexus_host="http://localhost:8081/${NEXUS_CONTEXT}"
root_user="admin"
base_dir="/opt/sonatype/nexus"
out_file="/tmp/out.json"
Expand Down
4 changes: 4 additions & 0 deletions charts/nexus3/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,10 @@ spec:
{{- else }}
value: {{ printf "-Xms%s -Xmx%s %s -Djava.util.prefs.userRoot=/nexus-data/javaprefs %s" .Values.envVars.jvmMinHeapSize .Values.envVars.jvmMaxHeapSize .Values.envVars.jvmAdditionalMemoryOptions .Values.envVars.jvmAdditionalOptions | quote }}
{{- end }}
{{- if not (eq .Values.ingress.path "/") }}
- name: NEXUS_CONTEXT
value: {{ .Values.ingress.path | replace "/" "" }}
{{- end -}}
{{- with .Values.env }}
{{- toYaml . | nindent 12 }}
{{- end }}
Expand Down
2 changes: 1 addition & 1 deletion charts/nexus3/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ spec:
- host: {{ . | quote }}
http:
paths:
- path: /
- path: {{ $.Values.ingress.path | quote }}
{{- if $ingressSupportsPathType }}
pathType: Prefix
{{- end }}
Expand Down
1 change: 1 addition & 0 deletions charts/nexus3/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ ingress:
enabled: false
annotations: {}
ingressClassName: ""
path: / # Note if you change path, you must prefix livenessProbe.httpGet.path & readinessProbe.httpGet.path with this string
hosts: []
# - nexus.local
tls: []
Expand Down