1
0

Actualiser Home

2025-01-31 10:09:12 +01:00
parent aff08a525d
commit c8a529613c
+3 -3
@@ -51,12 +51,12 @@ Une fois le fichier créer, on lance la commande :
![](https://git.yh.genj.fr/polaire/INFR010-Automatiser_deploiement_serveurd/raw/branch/main/screens/1.png) ![](https://git.yh.genj.fr/polaire/INFR010-Automatiser_deploiement_serveurd/raw/branch/main/screens/1.png)
# II - Connexion à Azure # II - Actions sur Azure
az login az login
## a- Créer un Service Principal dans Azure : ## II.1 - Créer un Service Principal dans Azure :
`az ad sp create-for-rbac --name "AnsibleServicePrincipal" --role="Contributor" --scopes="/subscriptions/<subscription_id>"` `az ad sp create-for-rbac --name "AnsibleServicePrincipal" --role="Contributor" --scopes="/subscriptions/<subscription_id>"`
@@ -78,7 +78,7 @@ autorisations daccès. |
} }
``` ```
## b- Configurer Ansible pour utiliser le Service Principal ## II.2 - Configurer Ansible pour utiliser le Service Principal
On utilise un fichier de configuration : On utilise un fichier de configuration :
Créer un fichier ~/.azure/credentials et ajouter : Créer un fichier ~/.azure/credentials et ajouter :