From c2e33fd4cf4564b6e8568a8520f4d97d335b1053 Mon Sep 17 00:00:00 2001 From: Emi Matchu Date: Mon, 10 Jun 2024 13:05:51 -0700 Subject: [PATCH] Replace run.sh with ansible-playbook I've learned more about Ansible, and that the flags I set by using `run.sh` are also settable with a `ansible.cfg` file! That's about the same amount of overhead, but enables everything else to be more standard. Neat! --- README.md | 4 ++-- ansible.cfg | 5 +++++ run.sh | 1 - 3 files changed, 7 insertions(+), 3 deletions(-) create mode 100644 ansible.cfg delete mode 100755 run.sh diff --git a/README.md b/README.md index 142fbae..237354f 100644 --- a/README.md +++ b/README.md @@ -17,9 +17,9 @@ just use them as idempotent command-line scripts!) service running Forgejo's official Linux binary. This is mostly a 1:1 port of [Forgejo's "Installation from binary" guide][fj-install]! -You can run them individually, or all at once, with `run.sh`: +You can run them individually, or all at once, with `ansible-playbook`: - run.sh setup-all.yml + ansible-playbook setup-all.yml If you're interested in setting up your own Forgejo service, this could be useful as a starting point, there's not much custom here! Just a couple things diff --git a/ansible.cfg b/ansible.cfg new file mode 100644 index 0000000..2271ddb --- /dev/null +++ b/ansible.cfg @@ -0,0 +1,5 @@ +[defaults] +inventory = inventory.cfg + +[privilege_escalation] +become_ask_pass = True diff --git a/run.sh b/run.sh deleted file mode 100755 index 3342888..0000000 --- a/run.sh +++ /dev/null @@ -1 +0,0 @@ -ansible-playbook -i inventory.cfg --ask-become-pass $1