Skip to content

Commit

Permalink
Merge pull request #449 from dtantsur/conductor-host
Browse files Browse the repository at this point in the history
Allow customizing conductor hostname
  • Loading branch information
metal3-io-bot authored Nov 29, 2023
2 parents d17fdb7 + a4f5ae5 commit 0b528ba
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ functionality:
inspection. (default `default,logs`)
- `HTTPD_ENABLE_SENDFILE` - Whether to activate the EnableSendfile apache
directive for httpd `(default, false)`
- `IRONIC_CONDUCTOR_HOST` - Host name of the current conductor (only makes
sense to change for a multinode setup). Defaults to the IP address used
for provisioning.

The ironic configuration can be overridden by various environment variables.
The following can serve as an example:
Expand Down
2 changes: 1 addition & 1 deletion ironic-config/ironic.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ my_ip = {{ env.IRONIC_IP }}
# If we run both API and conductor in the same pod, use localhost
host = localhost
{% else %}
host = {{ env.IRONIC_URL_HOST }}
host = {{ env.IRONIC_CONDUCTOR_HOST }}
{% endif %}

# If a path to a certificate is defined, use that first for webserver
Expand Down
3 changes: 3 additions & 0 deletions scripts/configure-ironic.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ export IRONIC_IPA_COLLECTORS=${IRONIC_IPA_COLLECTORS:-default,logs}

wait_for_interface_or_ip

# Hostname to use for the current conductor instance.
export IRONIC_CONDUCTOR_HOST=${IRONIC_CONDUCTOR_HOST:-${IRONIC_URL_HOST}}

export IRONIC_BASE_URL=${IRONIC_BASE_URL:-"${IRONIC_SCHEME}://${IRONIC_URL_HOST}:${IRONIC_ACCESS_PORT}"}
export IRONIC_INSPECTOR_BASE_URL=${IRONIC_INSPECTOR_BASE_URL:-"${IRONIC_INSPECTOR_SCHEME}://${IRONIC_URL_HOST}:${IRONIC_INSPECTOR_ACCESS_PORT}"}

Expand Down

0 comments on commit 0b528ba

Please sign in to comment.