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

Populate context.xml secret from value #39

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
4 changes: 4 additions & 0 deletions geoserver/latest/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,13 @@ geoserver:
EXAMPLE_DB_HOST=localhost
EXAMPLE_DB_USER=geoserver
EXAMPLE_DB_PASS=geoserver

context_xml: |

```

#### Description:
- `context_xml`: pupulate the secret for the Tomcat `context.xml` file.
- `chown_datadir`: toggle running `chown` to the `tomcat` UID/GID on the GeoServer data\_dir.
Disabling this might be desired when particular storage drivers requires to not change the ownership.
- `geoserver_extra_opts`: JVM options that will be appended to the default ones.
Expand Down
30 changes: 0 additions & 30 deletions geoserver/latest/context.xml

This file was deleted.

2 changes: 1 addition & 1 deletion geoserver/latest/templates/secrets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ metadata:
name: {{ include "geoserver.fullname" . }}-context
data:
context.xml: |-
{{ .Files.Get "context.xml" | b64enc }}
{{ .Values.geoserver.context_xml | b64enc }}
30 changes: 30 additions & 0 deletions geoserver/latest/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -165,3 +165,33 @@ geoserver:
EXAMPLE_DB_HOST=localhost
EXAMPLE_DB_USER=geoserver
EXAMPLE_DB_PASS=geoserver

context_xml: |
<Context>
<!-- Default set of monitored resources -->
<WatchedResource>WEB-INF/web.xml</WatchedResource>

<!-- Uncomment this to disable session persistence across Tomcat restarts -->
<!--
<Manager pathname="" />
-->

<!-- Uncomment this to enable Comet connection tacking (provides events
on session expiration as well as webapp lifecycle) -->
<!--
<Valve className="org.apache.catalina.valves.CometConnectionManagerValve" />
-->

<Resource
name="jdbc/postgres" auth="Container" type="javax.sql.DataSource"
driverClassName="org.postgresql.Driver"
url="jdbc:postgresql://127.0.0.1:5432/geoserver"
username="geoserver" password="geoserver"
initialSize="0" maxTotal="20" maxIdle="5" maxWaitMillis="2000" minIdle="0"
timeBetweenEvictionRunsMillis="30000"
minEvictableIdleTimeMillis="60000"
validationQuery="SELECT 1"
maxAge="600000"
rollbackOnReturn="true"
/>
</Context>