Add basic standard datasync check scripts
This commit is contained in:
		
							parent
							
								
									7500202af0
								
							
						
					
					
						commit
						70c5d661a3
					
				
					 3 changed files with 53 additions and 0 deletions
				
			
		
							
								
								
									
										20
									
								
								rattail_fabric2/deploy/rattail/check-datasync-queue.mako
									
										
									
									
									
										Executable file
									
								
							
							
						
						
									
										20
									
								
								rattail_fabric2/deploy/rattail/check-datasync-queue.mako
									
										
									
									
									
										Executable file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,20 @@
 | 
			
		|||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
TIMEOUT="$1"
 | 
			
		||||
if [ "$TIMEOUT" = "" ]; then
 | 
			
		||||
    echo "Usage: check-datasync-queue TIMEOUT"
 | 
			
		||||
    exit 3
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
cd ${envroot}
 | 
			
		||||
 | 
			
		||||
bin/rattail -c app/quiet.conf --no-versioning datasync --timeout $TIMEOUT check 2>&1
 | 
			
		||||
rc=$?
 | 
			
		||||
if [ $rc -eq 1 ]; then
 | 
			
		||||
    exit 2
 | 
			
		||||
elif [ $rc -ne 0 ]; then
 | 
			
		||||
    echo "unknown issue"
 | 
			
		||||
    exit 3
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
							
								
								
									
										20
									
								
								rattail_fabric2/deploy/rattail/check-datasync-watchers.mako
									
										
									
									
									
										Executable file
									
								
							
							
						
						
									
										20
									
								
								rattail_fabric2/deploy/rattail/check-datasync-watchers.mako
									
										
									
									
									
										Executable file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,20 @@
 | 
			
		|||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
TIMEOUT="$1"
 | 
			
		||||
if [ "$TIMEOUT" = "" ]; then
 | 
			
		||||
    echo "Usage: check-datasync-watchers TIMEOUT"
 | 
			
		||||
    exit 3
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
cd ${envroot}
 | 
			
		||||
 | 
			
		||||
bin/rattail -c app/datasync.conf -c app/quiet.conf --no-versioning datasync --timeout $TIMEOUT check-watchers 2>&1
 | 
			
		||||
rc=$?
 | 
			
		||||
if [ $rc -eq 1 ]; then
 | 
			
		||||
    exit 2
 | 
			
		||||
elif [ $rc -ne 0 ]; then
 | 
			
		||||
    echo "unknown issue"
 | 
			
		||||
    exit 3
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue