Fix the linking of the nginx configuration file (#458)
In this commit I'm adding some logic to ensure that the `entrypoint.sh` file handles a pre-existing `mattermost.conf` file within the nginx folder. During deployment of some more custom nginx configuration it was noticed that the linking process fails, because a file already exists with the filesystem. Signed-off-by: Akendo <akendo@akendo.eu>
This commit is contained in:
		
							parent
							
								
									b4482771f7
								
							
						
					
					
						commit
						068e654249
					
				| @ -11,6 +11,8 @@ if [ -f "/cert/cert.pem" -a -f "/cert/key-no-password.pem" ]; then | ||||
| else | ||||
|   echo "linking plain config" | ||||
| fi | ||||
| # Ensure that the configuration file is not present before linking.  | ||||
| test -w /etc/nginx/conf.d/mattermost.conf && rm /etc/nginx/conf.d/mattermost.conf | ||||
| # Linking Nginx configuration file | ||||
| ln -s -f /etc/nginx/sites-available/mattermost$ssl /etc/nginx/conf.d/mattermost.conf | ||||
| 
 | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Akendo
						Akendo