mirror of
				https://git.lapiole.org/dani/ansible-roles.git
				synced 2025-10-31 10:51:27 +01:00 
			
		
		
		
	Update to 2022-08-30 23:00
This commit is contained in:
		
							
								
								
									
										8
									
								
								roles/linstor_controller/templates/post-backup.j2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								roles/linstor_controller/templates/post-backup.j2
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| #!/bin/bash | ||||
|  | ||||
| set -eo pipefail | ||||
|  | ||||
| if [[ -e /home/lbkp/linstor/linstor_backup.zip ]]; then | ||||
|   echo Removing Linstor DB dump /home/lbkp/linstor/linstor_backup.zip | ||||
|   rm -f /home/lbkp/linstor/linstor_backup.zip | ||||
| fi | ||||
							
								
								
									
										18
									
								
								roles/linstor_controller/templates/pre-backup.j2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								roles/linstor_controller/templates/pre-backup.j2
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,18 @@ | ||||
| #!/bin/bash | ||||
|  | ||||
| set -eo pipefail | ||||
|  | ||||
| mkdir -p /home/lbkp/linstor/ | ||||
|  | ||||
| {% if linctl_ha %} | ||||
| # Check we are the current active node. Else, just skip the backup | ||||
| if [[ ! -e /var/lib/linstor/linstordb.mv.db ]]; then | ||||
|   echo Linstor DB not available on this node, skipping backup | ||||
|   exit 0 | ||||
| fi | ||||
| {% endif %} | ||||
|  | ||||
| echo Dumping linstor DB dump | ||||
| linstor controller backupdb linstor_backup | ||||
| echo Moving dump to /home/lbkp/linstor/linstor_backup.zip | ||||
| mv /var/lib/linstor/linstor_backup.zip /home/lbkp/linstor/ | ||||
		Reference in New Issue
	
	Block a user
	 Daniel Berteaud
					Daniel Berteaud