mirror of
				https://github.com/linuxserver/docker-swag.git
				synced 2025-11-04 15:02:38 +09:00 
			
		
		
		
	Init authelia and ldap configs
This commit is contained in:
		@@ -4,3 +4,24 @@
 | 
				
			|||||||
if [[ ! -f /config/nginx/proxy.conf ]]; then
 | 
					if [[ ! -f /config/nginx/proxy.conf ]]; then
 | 
				
			||||||
    cp /defaults/nginx/proxy.conf.sample /config/nginx/proxy.conf
 | 
					    cp /defaults/nginx/proxy.conf.sample /config/nginx/proxy.conf
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# copy authelia config files if they don't exist
 | 
				
			||||||
 | 
					if [[ ! -f /config/nginx/authelia-location.conf ]]; then
 | 
				
			||||||
 | 
					    cp /defaults/nginx/authelia-location.conf.sample /config/nginx/authelia-location.conf
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 | 
					if [[ ! -f /config/nginx/authelia-server.conf ]]; then
 | 
				
			||||||
 | 
					    cp /defaults/nginx/authelia-server.conf.sample /config/nginx/authelia-server.conf
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# copy old ldap config file to new location
 | 
				
			||||||
 | 
					if [[ -f /config/nginx/ldap.conf ]] && [[ ! -f /config/nginx/ldap-server.conf ]]; then
 | 
				
			||||||
 | 
					    cp /config/nginx/ldap.conf /config/nginx/ldap-server.conf
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# copy ldap config files if they don't exist
 | 
				
			||||||
 | 
					if [[ ! -f /config/nginx/ldap-location.conf ]]; then
 | 
				
			||||||
 | 
					    cp /defaults/nginx/ldap-location.conf.sample /config/nginx/ldap-location.conf
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 | 
					if [[ ! -f /config/nginx/ldap-server.conf ]]; then
 | 
				
			||||||
 | 
					    cp /defaults/nginx/ldap-server.conf.sample /config/nginx/ldap-server.conf
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -7,6 +7,6 @@ fi
 | 
				
			|||||||
if [[ -f /config/nginx/ldap.conf ]]; then
 | 
					if [[ -f /config/nginx/ldap.conf ]]; then
 | 
				
			||||||
    echo "/config/nginx/ldap.conf exists.
 | 
					    echo "/config/nginx/ldap.conf exists.
 | 
				
			||||||
        Please apply any customizations to /config/nginx/ldap-server.conf
 | 
					        Please apply any customizations to /config/nginx/ldap-server.conf
 | 
				
			||||||
        Ensure your nginx.conf is updated and remove /config/nginx/ldap.conf
 | 
					        Ensure your configs are updated and remove /config/nginx/ldap.conf
 | 
				
			||||||
        If you do not use this config, simply remove it."
 | 
					        If you do not use this config, simply remove it."
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user