gresockj commented on a change in pull request #5226:
URL: https://github.com/apache/nifi/pull/5226#discussion_r672233625
##########
File path: nifi-docker/dockermaven/sh/start.sh
##########
@@ -66,6 +67,15 @@ if [ -n "${NIFI_WEB_HTTP_PORT}" ]; then
prop_replace 'truststore' ''
${nifi_toolkit_props_file}
prop_replace 'truststoreType' ''
${nifi_toolkit_props_file}
prop_replace 'baseUrl'
"http://${NIFI_WEB_HTTP_HOST:-$HOSTNAME}:${NIFI_WEB_HTTP_PORT}"
${nifi_toolkit_props_file}
+
+ if [ -n "${NIFI_WEB_PROXY_HOST}" ]; then
+ echo 'NIFI_WEB_PROXY_HOST was set but NiFi is not configured to run in
a secure mode. Unsetting nifi.web.proxy.host.'
Review comment:
@jfrazee, I may be running this incorrectly, but I noticed this print
out when I ran the docker image built from the dockermaven build:
```
NIFI_WEB_PROXY_HOST was set but NiFi is not configured to run in a secure
mode. Will not update nifi.web.proxy.host.
```
This was the command I used:
```
docker run --name nifi \
-p 8443:8443 \
-e NIFI_WEB_PROXY_HOST=localhost \
apache/nifi:NIFI-8783
```
However, I was able to log into NiFi at https://localhost:8443, which
indicates NiFi is configured to run in a secure mode.
##########
File path: nifi-docker/dockermaven/sh/start.sh
##########
@@ -66,6 +67,15 @@ if [ -n "${NIFI_WEB_HTTP_PORT}" ]; then
prop_replace 'truststore' ''
${nifi_toolkit_props_file}
prop_replace 'truststoreType' ''
${nifi_toolkit_props_file}
prop_replace 'baseUrl'
"http://${NIFI_WEB_HTTP_HOST:-$HOSTNAME}:${NIFI_WEB_HTTP_PORT}"
${nifi_toolkit_props_file}
+
+ if [ -n "${NIFI_WEB_PROXY_HOST}" ]; then
+ echo 'NIFI_WEB_PROXY_HOST was set but NiFi is not configured to run in
a secure mode. Unsetting nifi.web.proxy.host.'
Review comment:
Yep, user error, sorry about that -- looks like I typo'ed "gh pr
checkout 5216" instead of 5226. I'll rebuild and try again.
##########
File path: nifi-docker/dockermaven/sh/start.sh
##########
@@ -66,6 +67,15 @@ if [ -n "${NIFI_WEB_HTTP_PORT}" ]; then
prop_replace 'truststore' ''
${nifi_toolkit_props_file}
prop_replace 'truststoreType' ''
${nifi_toolkit_props_file}
prop_replace 'baseUrl'
"http://${NIFI_WEB_HTTP_HOST:-$HOSTNAME}:${NIFI_WEB_HTTP_PORT}"
${nifi_toolkit_props_file}
+
+ if [ -n "${NIFI_WEB_PROXY_HOST}" ]; then
+ echo 'NIFI_WEB_PROXY_HOST was set but NiFi is not configured to run in
a secure mode. Unsetting nifi.web.proxy.host.'
Review comment:
Ok, re-ran on the correct branch -- I verified that this works as
described when setting NIFI_WEB_PROXY_HOST with either NIFI_WEB_HTTP_HOST or
NIFI_WEB_HTTPS_HOST.
Thanks for the quick work on this one, @jfrazee!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]