Environment Variables#
Complete reference of environment variables supported by GeoServer CLI.
Configuration Selection#
GEOSRVCLI_CONFIG#
Selects the configuration file to use.
| |
Precedence: CLI flag --config > GEOSRVCLI_CONFIG > default
GeoServer Connection#
GEOSRVCLI_ENDPOINT#
GeoServer REST API base URL.
| |
Precedence: CLI flag --base-url > GEOSRVCLI_ENDPOINT > config file > default
GEOSRVCLI_USERNAME#
GeoServer username for HTTP Basic Authentication.
| |
Precedence: CLI flag --user > GEOSRVCLI_USERNAME > config file > default
GEOSRVCLI_PASSWORD#
GeoServer password for HTTP Basic Authentication.
| |
Precedence: CLI flag --password > GEOSRVCLI_PASSWORD > config file > default
!!! warning “Security” Never commit passwords to version control. Use environment variables or secure config files.
GEOSRVCLI_TIMEOUT#
HTTP request timeout duration.
| |
Precedence: CLI flag --timeout > GEOSRVCLI_TIMEOUT > config file > default (30s)
Default Workspace#
GEOSRVCLI_DEFAULT_WORKSPACE#
Default workspace name to use when --workspace flag is not provided.
| |
Usage:
| |
PostGIS Connection#
GEOSRVCLI_POSTGIS_HOST#
PostGIS database hostname.
| |
GEOSRVCLI_POSTGIS_PORT#
PostGIS database port.
| |
Default: 5432
GEOSRVCLI_POSTGIS_DATABASE#
PostGIS database name.
| |
GEOSRVCLI_POSTGIS_USER#
PostGIS database username.
| |
GEOSRVCLI_POSTGIS_PASSWORD#
PostGIS database password.
| |
!!! warning “Security” PostGIS passwords should be kept secure. Use environment variables or secure config files.
GEOSRVCLI_POSTGIS_SCHEMA#
PostGIS schema name for table discovery.
| |
Default: public
GEOSRVCLI_POSTGIS_SSLMODE#
PostgreSQL SSL mode.
| |
Valid values: disable, allow, prefer, require, verify-ca, verify-full
Default: disable
Environment Variable Precedence#
For all settings, the precedence is:
- CLI flags (highest priority)
- Environment variables
- Configuration file
- Default values (lowest priority)
Examples#
Complete Environment Setup#
| |
CI/CD Environment#
| |
Development Override#
| |