Skip to content

Commit

Permalink
Merge pull request #44 from tuxmea/additional_configs
Browse files Browse the repository at this point in the history
Add additional parameters, rework entrypoint order
  • Loading branch information
tuxmea authored Jan 5, 2024
2 parents 254b045 + 739cee8 commit 43f6122
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 1 deletion.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ The following environment variables are supported:
| **PUPPETSERVER_GRAPHITE_PORT** | Only used if **PUPPETSERVER_GRAPHITE_EXPORTER_ENABLED** is set to `true`. Port of the graphite server where puppet should push metrics to. <br><br> Default to `9109` |
| **PUPPETSERVER_ENVIRONMENT_TIMEOUT** | Configure the environment timeout<br><br> Defaults to `unlimited` |
| **PUPPETSERVER_ENABLE_ENV_CACHE_DEL_API** | Enable the puppet admin api endpoint via certificates to allow clearing environment caches<br><br> Defaults to `true` |
| **ENVIRONMENTPATH** | Set an environmentpath<br><br> Defaults to `/etc/puppetlabs/code/environments` |
| **HIERACONFIG** | Set a hiera_config entry in puppet.conf file<br><br> Defaults to `$confdir/hiera.yaml` |

## Initialization Scripts

Expand Down
4 changes: 3 additions & 1 deletion puppetserver/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ ENV PUPPETSERVER_JAVA_ARGS="-Xms1024m -Xmx1024m" \
PUPPETSERVER_GRAPHITE_PORT=9109 \
PUPPETSERVER_GRAPHITE_HOST=exporter \
PUPPETSERVER_ENVIRONMENT_TIMEOUT=unlimited \
PUPPETSERVER_ENABLE_ENV_CACHE_DEL_API=true
PUPPETSERVER_ENABLE_ENV_CACHE_DEL_API=true \
ENVIRONMENTPATH=/etc/puppetlabs/code/environments \
HIERACONFIG="$confdir/hiera.yaml"

# NOTE: this is just documentation on defaults
EXPOSE 8140
Expand Down
4 changes: 4 additions & 0 deletions puppetserver/docker-entrypoint.d/56-set-environmentpath.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash
#
puppet config set --section server environmentpath $ENVIRONMENTPATH

4 changes: 4 additions & 0 deletions puppetserver/docker-entrypoint.d/57-set-hiera_config.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash
#
puppet config set --section server hiera_config $HIERACONFIG

Empty file modified puppetserver/docker-entrypoint.d/88-enable-cache-delete-api.sh
100644 → 100755
Empty file.
File renamed without changes.

0 comments on commit 43f6122

Please sign in to comment.