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

[bitnami/matomo] Added MATOMO_PROXY_IP_READ_LAST_IN_LIST env variable #73995

Closed
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
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,11 @@ EOF
ini-file set -s "General" -k "proxy_host_headers[]" -v "$MATOMO_PROXY_HOST_HEADER" "$MATOMO_CONF_FILE"
fi

if ! is_empty_value "$MATOMO_PROXY_IP_READ_LAST_IN_LIST"; then
info "Configuring Matomo to read the last IP in the list"
ini-file set -s "General" -k "proxy_ip_read_last_in_list" -v "$MATOMO_PROXY_IP_READ_LAST_IN_LIST" "$MATOMO_CONF_FILE"
fi

# Database SSL
if is_boolean_yes "$MATOMO_ENABLE_DATABASE_SSL"; then
info "Enabling database SSL"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ matomo_env_vars=(
MATOMO_ENABLE_ASSUME_SECURE_PROTOCOL
MATOMO_ENABLE_FORCE_SSL
MATOMO_ENABLE_PROXY_URI_HEADER
MATOMO_PROXY_IP_READ_LAST_IN_LIST
MATOMO_USERNAME
MATOMO_PASSWORD
MATOMO_EMAIL
Expand Down Expand Up @@ -96,6 +97,7 @@ export MATOMO_PROXY_CLIENT_HEADER="${MATOMO_PROXY_CLIENT_HEADER:-}" # only used
export MATOMO_ENABLE_ASSUME_SECURE_PROTOCOL="${MATOMO_ENABLE_ASSUME_SECURE_PROTOCOL:-no}" # only used during the first initialization
export MATOMO_ENABLE_FORCE_SSL="${MATOMO_ENABLE_FORCE_SSL:-no}" # only used during the first initialization
export MATOMO_ENABLE_PROXY_URI_HEADER="${MATOMO_ENABLE_PROXY_URI_HEADER:-no}" # only used during the first initialization
export MATOMO_PROXY_IP_READ_LAST_IN_LIST="${MATOMO_PROXY_IP_READ_LAST_IN_LIST:-1}"

# Matomo credentials
export MATOMO_USERNAME="${MATOMO_USERNAME:-user}" # only used during the first initialization
Expand Down
1 change: 1 addition & 0 deletions bitnami/matomo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ Bitnami provides up-to-date versions of MariaDB and Matomo, including security p
| `MATOMO_SKIP_BOOTSTRAP` | Whether to perform initial bootstrapping for the application. | `nil` |
| `MATOMO_PROXY_HOST_HEADER` | Specify the host IP HTTP Header. Usually HTTP_X_FORWARDED_HOST. No defaults. | `nil` |
| `MATOMO_PROXY_CLIENT_HEADER` | Specify the client IP HTTP Header. Usually HTTP_X_FORWARDED_FOR. | `nil` |
| `MATOMO_PROXY_IP_READ_LAST_IN_LIST` | Specify if the last IP in the `X-FORWARDED-FOR` list should be read. | `1` |
| `MATOMO_ENABLE_ASSUME_SECURE_PROTOCOL` | Enable assume_secure_protocol in Matomo configuration file. | `no` |
| `MATOMO_ENABLE_FORCE_SSL` | Enable force_ssl in Matomo configuration file. | `no` |
| `MATOMO_ENABLE_PROXY_URI_HEADER` | Enable proxy_uri_header in Matomo configuration file. | `no` |
Expand Down
Loading