mirror of
				https://github.com/lingble/twenty.git
				synced 2025-10-31 20:57:55 +00:00 
			
		
		
		
	Fail entrypoint if migration fails (#8590)
If migration fails for some reason, the script runs anyway and creates the file which indicates that migration is complete. This is obviously not cool. If database is not available for some reason and migrations fail, the container should exit, not continue. Relevant stack overflow: https://stackoverflow.com/a/2871034
This commit is contained in:
		 Sasank Chilamkurthy
					Sasank Chilamkurthy
				
			
				
					committed by
					
						 GitHub
						GitHub
					
				
			
			
				
	
			
			
			 GitHub
						GitHub
					
				
			
						parent
						
							4f2019edae
						
					
				
				
					commit
					d90c3110cf
				
			| @@ -1,4 +1,5 @@ | ||||
| #!/bin/sh | ||||
| set -e | ||||
|  | ||||
| # Check if the initialization has already been done and that we enabled automatic migration | ||||
| if [ "${ENABLE_DB_MIGRATIONS}" = "true" ] && [ ! -f /app/docker-data/db_status ]; then | ||||
|   | ||||
		Reference in New Issue
	
	Block a user