mirror of
https://github.com/khuedoan/homelab.git
synced 2024-12-23 01:04:32 +07:00
12143551c7
https://github.com/khuedoan/homelab/issues/92 Using SSH key with passphrase requires ssh-agent, which the tools container doesn't have https://stackoverflow.com/questions/50277495/how-to-run-an-ansible-playbook-with-a-passphrase-protected-ssh-private-key
23 lines
347 B
Makefile
23 lines
347 B
Makefile
.POSIX:
|
|
|
|
env ?= "prod"
|
|
|
|
default: boot cluster
|
|
|
|
~/.ssh/id_ed25519:
|
|
ssh-keygen -t ed25519 -P '' -f "$@"
|
|
|
|
boot: ~/.ssh/id_ed25519
|
|
ansible-playbook \
|
|
--inventory inventories/${env}.yml \
|
|
boot.yml
|
|
|
|
cluster:
|
|
ansible-playbook \
|
|
--inventory inventories/${env}.yml \
|
|
cluster.yml
|
|
|
|
console:
|
|
ansible-console \
|
|
--inventory inventories/${env}.yml
|