Inchdev.github_deploy_key
Nazwa ról
Ta rola pozwala na dodawanie lub usuwanie klucza SSH z kluczy wdrożeniowych repozytorium GitHub za pomocą API GitHub: https://developer.github.com/v3/repos/keys/
Wymagania
Brak
Zmienne Roli
Zmienna, które mogą być przekazywane do tej roli oraz krótki opis:
github_deploy_key_readonly: true # Czy klucz wdrożeniowy powinien być tylko do odczytu
github_api_url: https://api.github.com/repos/{{github_repository}}/keys # Nie należy tego nadpisywać, to jest używane do rozwiązywania adresu URL API GitHub
deploy_key_operation: present # present: Dodaj klucz, absent: usuń klucz
github_deploy_key_name: ansible-generated # Tytuł twojego klucza
github_deploy_key: ssh-rsa foobar # Zawartość twojego klucza (wymagane)
# Możesz użyć swojego nazwy użytkownika i hasła (jeśli 2FA jest wyłączone):
github_username: myUsername
github_password: myPassword
# Lub użyj preferowanego sposobu, tokena uwierzytelniającego, który możesz stworzyć tutaj: https://github.com/settings/tokens
github_access_token: myAccessTokenThatIsSuperLongAndUsuallyInTheVault
Zależności
Brak
Przykładowy Playbook
- hosts: serwery
roles:
- role: github_deploy_key
vars:
github_repository: owner/nazwa_repo
github_access_token: myAccessTokenThatIsSuperLongAndUsuallyInTheVault
github_deploy_key: ssh-rsa tototata
github_deploy_key_readonly: false
- hosts: serwery
roles:
- role: github_deploy_key
vars:
github_repository: owner/nazwa_repo
github_username: myUsername
github_password: myPassword
github_deploy_key: ssh-rsa tototata
- hosts: serwery
roles:
- role: github_deploy_key
vars:
deploy_key_operation: absent
github_repository: owner/nazwa_repo
github_deploy_key_id: 4242
github_access_token: myAccessTokenThatIsSuperLongAndUsuallyInTheVault
Licencja
BSD
Informacje o autorze
Zainstaluj
ansible-galaxy install Inchdev.github_deploy_key
Licencja
Unknown
Pobrania
127
Właściciel