mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-11-01 05:21:32 +08:00 
			
		
		
		
	feat(config): add Cookies.cookiePath option to config
defaults to "/" as previously set by default options
This commit is contained in:
		
							parent
							
								
									48d4093274
								
							
						
					
					
						commit
						3c8723a404
					
				| @ -28,6 +28,15 @@ keyPath= | |||||||
| # expressjs shortcuts are supported: loopback(127.0.0.1/8, ::1/128), linklocal(169.254.0.0/16, fe80::/10), uniquelocal(10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16, fc00::/7) | # expressjs shortcuts are supported: loopback(127.0.0.1/8, ::1/128), linklocal(169.254.0.0/16, fe80::/10), uniquelocal(10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16, fc00::/7) | ||||||
| trustedReverseProxy=false | trustedReverseProxy=false | ||||||
| 
 | 
 | ||||||
|  | 
 | ||||||
|  | [Cookies] | ||||||
|  | # Use this setting to constrain the current instance's "Path" value for the set cookies | ||||||
|  | # This can be useful, when you have several instances running on the same domain, under different paths (e.g. by using a reverse proxy). | ||||||
|  | # It prevents your instances from overwriting each others' cookies. | ||||||
|  | # e.g. if you have https://your-domain.com/triliumNext/instanceA and https://your-domain.com/triliumNext/instanceB | ||||||
|  | # you would want to set the cookiePath value to "/triliumNext/instanceA" for your first and "/triliumNext/instanceB" for your second instance | ||||||
|  | cookiePath=/ | ||||||
|  | 
 | ||||||
| [Sync] | [Sync] | ||||||
| #syncServerHost= | #syncServerHost= | ||||||
| #syncServerTimeout= | #syncServerTimeout= | ||||||
|  | |||||||
| @ -32,6 +32,9 @@ export interface TriliumConfig { | |||||||
|         keyPath: string; |         keyPath: string; | ||||||
|         trustedReverseProxy: boolean | string; |         trustedReverseProxy: boolean | string; | ||||||
|     }; |     }; | ||||||
|  |     Cookies: { | ||||||
|  |         cookiePath: string; | ||||||
|  |     } | ||||||
|     Sync: { |     Sync: { | ||||||
|         syncServerHost: string; |         syncServerHost: string; | ||||||
|         syncServerTimeout: string; |         syncServerTimeout: string; | ||||||
| @ -76,6 +79,11 @@ const config: TriliumConfig = { | |||||||
|             process.env.TRILIUM_NETWORK_TRUSTEDREVERSEPROXY || iniConfig.Network.trustedReverseProxy || false |             process.env.TRILIUM_NETWORK_TRUSTEDREVERSEPROXY || iniConfig.Network.trustedReverseProxy || false | ||||||
|     }, |     }, | ||||||
| 
 | 
 | ||||||
|  |     Cookies: { | ||||||
|  |         cookiePath: | ||||||
|  |             process.env.TRILIUM_COOKIES_COOKIEPATH || iniConfig?.Cookies?.cookiePath || "/" | ||||||
|  |     }, | ||||||
|  | 
 | ||||||
|     Sync: { |     Sync: { | ||||||
|         syncServerHost: |         syncServerHost: | ||||||
|             process.env.TRILIUM_SYNC_SERVER_HOST || iniConfig?.Sync?.syncServerHost || "", |             process.env.TRILIUM_SYNC_SERVER_HOST || iniConfig?.Sync?.syncServerHost || "", | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Panagiotis Papadopoulos
						Panagiotis Papadopoulos