change
This commit is contained in:
23
scripts/test-connection.sh
Normal file
23
scripts/test-connection.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
# Test de connexion aux serveurs
|
||||
|
||||
echo "=== Test de connexion aux serveurs ==="
|
||||
|
||||
# Test staging
|
||||
echo "Test de connexion à staging..."
|
||||
ansible -i inventories/staging/hosts.yml minecraft_servers -m ping
|
||||
|
||||
# Test production
|
||||
echo "Test de connexion à production..."
|
||||
ansible -i inventories/production/hosts.yml minecraft_servers -m ping
|
||||
|
||||
echo ""
|
||||
echo "=== Test de privilèges sudo ==="
|
||||
|
||||
# Test sudo staging
|
||||
echo "Test sudo sur staging..."
|
||||
ansible -i inventories/staging/hosts.yml minecraft_servers -b -m command -a "whoami"
|
||||
|
||||
# Test sudo production
|
||||
echo "Test sudo sur production..."
|
||||
ansible -i inventories/production/hosts.yml minecraft_servers -b -m command -a "whoami"
|
Reference in New Issue
Block a user