Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled)

Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled)

book

Article ID: KB0082630

calendar_today

Updated On:

Products Versions
Spotfire Data Science 6.x

Description

Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled)

Issue/Introduction

Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled)

Resolution

Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled)

1. Enable iptables and start the iptables service

service iptables restart
chkconfig --level 345 iptables on

 2. Set the default iptables rules and confirm that Spotfire Data Science works fine

For this example, we will fully open up iptables' rules:
#for cleaning all the existing rules
iptables -F
 
#fully open up incoming, outgoing and forwarding traffic
iptables --policy INPUT ACCEPT
iptables --policy OUTPUT ACCEPT
iptables --policy FORWARD ACCEPT
 
#saving the changes not to lose them when iptables are restarted
service iptables save

 3. Make these 2 changes in the $CHORUS_HOME/releases/<your 6.x release or higher>/vendor/nginx/nginx.conf.erb

a) Use vi command (:set number) to show the line numbers and change line 166 from the below depicted value (proxy_set_header    Host $host:$server_port;)
(see the attached screenshot)
to (proxy_set_header    Host $host;) as shown in the attached screenshot.

b) Change line 202 from the below depicted value (proxy_set_header    Host $host:$server_port;)
(see the attached screenshot)
to (proxy_set_header    Host $host;) as shown in the attached screenshot:

 

4. Configure port following 

Run these commands so that Spotfire Data Science is available on port 443 by forwarding the traffic to the SSL enabled Spotfire Data Science that is running on 8443:

iptables -t nat -I PREROUTING --src 0/0 -p tcp --dport 443 -j REDIRECT --to-ports 8443
iptables -A FORWARD -p tcp -m tcp --dport 443 -j ACCEPT
Now try accessing Spotfire Data Science from your web browser with https://your_hostname link (without specifying any port  - which means 443 will be used with HTTPS protocol).

Attachments

Configure Spotfire Data Science to redirect port 8443 to 443 (when SSL is enabled) get_app