add ansible playbook setup
This commit is contained in:
parent
78bfbc3ed6
commit
2a914766ba
3 changed files with 123 additions and 0 deletions
17
bootstrap/bootstrap.sh
Executable file
17
bootstrap/bootstrap.sh
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
if ! command -v uv >/dev/null 2>&1; then
|
||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
fi
|
||||
|
||||
if [[ -d ~/.config/dotfiles ]]; then
|
||||
|
||||
# dotfiles are cloned, executed localy
|
||||
uvx --with ansible --from ansible-core ansible-playbook --ask-become-pass bootstrap.yaml
|
||||
|
||||
else
|
||||
|
||||
# dotfiles are not cloned, executed remotly
|
||||
uvx --with ansible --from ansible-core ansible-pull --ask-become-pass --url ssh://git@git.alecodes.page:24062/alecodes/dots.git bootstrap/bootstrap.yaml
|
||||
|
||||
fi
|
||||
Loading…
Add table
Add a link
Reference in a new issue