feat: add V Rising server #22
| @ -20,9 +20,8 @@ editWithRestart() { | ||||
|     local full_path_file_to_edit="${1}" | ||||
|     nano "${full_path_file_to_edit}" | ||||
|     stdout "The server will now be restarted and you will be attached to the logs." | ||||
|     stdout "Use ctrl-c to detach from the logs (the service will continue to run)" | ||||
|     sleep 2 | ||||
|     (cd "${VRISING_COMPOSE_HOME}" && docker-compose restart && docker-compose logs -f) | ||||
|     stdout "Use ctrl-c to detach from the logs (the service will continue to run in background)" | ||||
|     (cd "${VRISING_COMPOSE_HOME}" && bash -c "docker-compose restart && docker-compose logs -f") | ||||
| } | ||||
| 
 | ||||
| USERNAME="${1}" | ||||
| @ -53,7 +52,7 @@ Select one of the following actions: | ||||
| """ | ||||
| 
 | ||||
|     ACTION="-1" | ||||
|     read -r ACTION | ||||
|     read -rp "> " ACTION | ||||
| 
 | ||||
|     case "${ACTION}" in | ||||
|         0) | ||||
| @ -67,18 +66,15 @@ Select one of the following actions: | ||||
|             ;; | ||||
|         3) | ||||
|             stdout "Use ctrl-c to detach from the logs at any time" | ||||
|             sleep 2 | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && docker-compose logs -f) | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && bash -c "docker-compose logs -f") | ||||
|             ;; | ||||
|         4) | ||||
|             stdout "Use ctrl-c to detach from the logs at any time" | ||||
|             sleep 2 | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && docker-compose restart && docker-compose logs -f) | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && bash -c "docker-compose restart && docker-compose logs -f") | ||||
|             ;; | ||||
|         5) | ||||
|             stdout "Use ctrl-c to detach from the logs at any time" | ||||
|             sleep 2 | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && docker-compose down -v && sleep 1 && docker-compose up -d && docker-compose logs -f) | ||||
|             (cd "${VRISING_COMPOSE_HOME}" && bash -c "docker-compose down -v && sleep 1 && docker-compose up -d && docker-compose logs -f") | ||||
|             ;; | ||||
|         *) | ||||
|             stderr "The provided input is not valid. Please chose from the listed actions" | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user