Update .gitlab-ci.yml
This commit is contained in:
		
							parent
							
								
									bf0f0c309f
								
							
						
					
					
						commit
						67dcec4ae0
					
				@ -53,13 +53,10 @@ deploy:datapacks:
 | 
				
			|||||||
    - chmod 644 ~/.ssh/known_hosts
 | 
					    - chmod 644 ~/.ssh/known_hosts
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    - cd datapacks
 | 
					    - cd datapacks
 | 
				
			||||||
    - rsync -avz out/ "$SERVER_HOST":"$WPD_FOLDER" --delete --exclude bukkit
 | 
					    - rsync -avz out/ "$SERVER_HOST":"$WPD_FOLDER/world/datapacks" --delete --exclude bukkit
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    - ssh "$SERVER_HOST" mcrcon -H localhost -p minecraft "minecraft:reload"
 | 
					    - ssh "$SERVER_HOST" mcrcon -H localhost -p minecraft "minecraft:reload"
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    - cd ../resourcepack-out
 | 
					 | 
				
			||||||
    - sha1sum resourcepack.zip
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
  only:
 | 
					  only:
 | 
				
			||||||
    refs:
 | 
					    refs:
 | 
				
			||||||
      - master
 | 
					      - master
 | 
				
			||||||
@ -81,9 +78,9 @@ deploy:resourcepack:
 | 
				
			|||||||
    - echo "$SSH_KNOWN_HOSTS" > ~/.ssh/known_hosts
 | 
					    - echo "$SSH_KNOWN_HOSTS" > ~/.ssh/known_hosts
 | 
				
			||||||
    - chmod 644 ~/.ssh/known_hosts
 | 
					    - chmod 644 ~/.ssh/known_hosts
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    - cd ../resourcepack-out
 | 
					    - cd resourcepack-out
 | 
				
			||||||
    - shasum= $(sha1sum resourcepack.zip | awk '{ print $1 }'
 | 
					    - SHASUM= $(sha1sum resourcepack.zip | awk '{ print $1 }'
 | 
				
			||||||
    - ssh "$SERVER_HOST" mcrcon -H localhost -p minecraft "minecraft:say Server restart in 2 minutes"
 | 
					    - ssh "$SERVER_HOST" (cd "WPD_FOLDER" && sed-i server.properties "s/resource-pack-sha1=.*/resource-pack-sha1=$SHASUM")
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
  only:
 | 
					  only:
 | 
				
			||||||
    refs:
 | 
					    refs:
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user