Compare commits
2 Commits
cf1f81f1ef
...
60f21a56d9
| Author | SHA1 | Date | |
|---|---|---|---|
| 60f21a56d9 | |||
| 886fe1d9ac |
18
check_service.sh
Executable file
18
check_service.sh
Executable file
@@ -0,0 +1,18 @@
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
SERVICE="docker"
|
||||
|
||||
echo "Verific serviciul: $SERVICE"
|
||||
|
||||
if systemctl is-active --quiet $SERVICE; then
|
||||
echo "Serviciul $SERVICE ruleaza"
|
||||
|
||||
else
|
||||
echo "Serviciul $SERVICE NU ruleaza"
|
||||
echo "Pornesc serviciul..."
|
||||
systemctl start $SERVICE
|
||||
echo "Serviciul a fost pornit"
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user