mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	update settings comments to describe how to setup for ipv6 (#1675)
* change default server bind to support ipv6 and ipv4 to close #1674 * Add comment re ipv6 so folk know it's capable * slightly more words re ipv6 config * Leave defaults as ipv4 but add doc to settings
This commit is contained in:
		
				
					committed by
					
						
						Nick O'Leary
					
				
			
			
				
	
			
			
			
						parent
						
							3190de873e
						
					
				
				
					commit
					e691351976
				
			
							
								
								
									
										4
									
								
								red.js
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								red.js
									
									
									
									
									
								
							@@ -192,7 +192,7 @@ try {
 | 
			
		||||
    if (err.code == "unsupported_version") {
 | 
			
		||||
        console.log("Unsupported version of node.js:",process.version);
 | 
			
		||||
        console.log("Node-RED requires node.js v4 or later");
 | 
			
		||||
    } else if  (err.code == "not_built") {
 | 
			
		||||
    } else if (err.code == "not_built") {
 | 
			
		||||
        console.log("Node-RED has not been built. See README.md for details");
 | 
			
		||||
    } else {
 | 
			
		||||
        console.log("Failed to start server:");
 | 
			
		||||
@@ -276,7 +276,7 @@ function getListenPath() {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    var listenPath = 'http'+(settings.https?'s':'')+'://'+
 | 
			
		||||
                    (settings.uiHost == '0.0.0.0'?'127.0.0.1':settings.uiHost)+
 | 
			
		||||
                    (settings.uiHost == '::'?'localhost':(settings.uiHost == '0.0.0.0'?'127.0.0.1':settings.uiHost))+
 | 
			
		||||
                    ':'+port;
 | 
			
		||||
    if (settings.httpAdminRoot !== false) {
 | 
			
		||||
        listenPath += settings.httpAdminRoot;
 | 
			
		||||
 
 | 
			
		||||
@@ -23,6 +23,7 @@ module.exports = {
 | 
			
		||||
    uiPort: process.env.PORT || 1880,
 | 
			
		||||
 | 
			
		||||
    // By default, the Node-RED UI accepts connections on all IPv4 interfaces.
 | 
			
		||||
    // To listen on all IPv6 addresses, set uiHost to "::",
 | 
			
		||||
    // The following property can be used to listen on a specific interface. For
 | 
			
		||||
    // example, the following would only allow connections from the local machine.
 | 
			
		||||
    //uiHost: "127.0.0.1",
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user