Just writing this for two reasons, one would be to help out after I spent many hours figuring this out since there wasn't any documentation on the Non Docker version of Portainer, and maybe get Terramaster development team to add a few things in one file to make it easier for others in the future.
This began because I have a Java applet that uses port 9443 and no easy way to change it. Portainer also uses that port for the https service. After a lot of searching, I found nothing online on how to do this. So I started looking at the startup service for Portainer in TOS 5.1.
If you look at the startup variable listed in the service (/Volume1/@apps/Portainer/init.d/service):
path=$(dirname $(readlink -f "${BASH_SOURCE[0]}"))
ThisPath=$(dirname "$path")
program="$ThisPath/portainer/portainer"
program_name=$(basename "$program")
tunnel_port=18000
program_port=19000
#program_data=$(ter_share_add -name "Portainer")
program_log=/var/log/portainer.log
proxy_file=/etc/nginx/conf.d/portainer.conf
default="$ThisPath/config/portainer.default"
There is a tunnel_port and a program_port listed, and it is easy to just change these port numbers if needed....
By simply running the executable with the help flag, I found the ports I needed:
--bind-https=:"9443" Address and port to serve Portainer via https
So by adding these to the Variable list above:
tunnel_port=18000
program_port=19000
https_port=9443
and updating the start command again in the service file:
$program --bind=":$program_port" --bind-https=:"$https_port" --tunnel-port="$tunnel_port" -d "$ThisPath" --admin-password-file="$default" > $program_log 2>&1 &
Just change the port in the variable, and restart the service and Voila....
Hope this helps someone in the future....
Steve
Changing Portainer UI ports number
Discussion about Docker
Jump to
- GENERAL
- ↳ News & Announcements
- ↳ Know More About TOS 5
- ↳ Know More About TOS 6
- ↳ Lounge and Boast
- TNAS (TerraMaster NAS)
- ↳ FAQ & User Guides
- ↳ Initialization & installation
- ↳ System Configuration
- ↳ File Service
- ↳ Networking
- ↳ Storage
- ↳ Backup & restore
- ↳ Hardware
- ↳ Applications
- ↳ Update Notice
- ↳ TOS
- ↳ Initialization
- ↳ System Update
- ↳ System Configuration
- ↳ Privileges
- ↳ Network & Remote Access
- ↳ File Services
- ↳ Storage
- ↳ Compatibility
- ↳ System Resources
- ↳ Security
- ↳ Mobile Apps and Desktop Clients
- ↳ Data Backup
- ↳ How to back up? Which one is right for me?
- ↳ TerraSync
- ↳ Centralized Backup
- ↳ Duple Backup
- ↳ USB Copy
- ↳ Snapshot
- ↳ CloudSync
- ↳ TFM Backup
- ↳ TFSS
- ↳ Rsync
- ↳ Time Machine
- ↳ Multimedia
- ↳ DLNA/Multimedia Services
- ↳ Multimedia Server
- ↳ Terra Photos
- ↳ Plex
- ↳ Emby
- ↳ Jellyfin
- ↳ Virtualization
- ↳ Docker
- ↳ Virtual Machines
- ↳ Other Applications
- ↳ iSCSI Target
- ↳ Surveillance Manager
- ↳ VPN Server
- ↳ Download
- ↳ Web Server/PHP/MySQL/MariaDB
- ↳ Terra Search
- ↳ Others
- ↳ New Features Wanted
- ↳ Developer Discussion Room
- ↳ Hardware, Power and Accessories
- TDAS (TerraMaster DAS)
- ↳ FAQ & User Guides
- ↳ Thunderbolt 3 Series
- ↳ USB Series
- ↳ Thunderbolt 3 Series
- ↳ USB Series