summaryrefslogtreecommitdiffstats
path: root/ansible
diff options
context:
space:
mode:
authorFelix Ableitner <me@nutomic.com>2020-07-01 14:51:52 +0200
committerFelix Ableitner <me@nutomic.com>2020-07-01 14:51:52 +0200
commitfb2b8994c7b17b8cae0b9d562fce53cb7dbe660c (patch)
tree724fbe060a4d91034c931dfdd81335386fa26ed2 /ansible
parent95f59a027248440b16107192cb507b7c182514de (diff)
Improve comments in ansible inventory
Diffstat (limited to 'ansible')
-rw-r--r--ansible/inventory.example9
-rw-r--r--ansible/lemmy.yml2
-rw-r--r--ansible/lemmy_dev.yml5
3 files changed, 13 insertions, 3 deletions
diff --git a/ansible/inventory.example b/ansible/inventory.example
index 139e4ca3..c5f98653 100644
--- a/ansible/inventory.example
+++ b/ansible/inventory.example
@@ -1,6 +1,11 @@
[lemmy]
-# define the username and hostname that you use for ssh connection, and specify the domain
-# old default for lemmy_base_dir was /lemmy
+# to get started, copy this file to `inventory` and adjust the values below.
+# - `myuser@example.com`: replace with the destination you use to connect to your server via ssh
+# - `domain=example.com`: replace `example.com` with your lemmy domain
+# - `letsencrypt_contact_email=your@email.com` replace `your@email.com` with your email address,
+# to get notifications if your ssl cert expires
+# - `lemmy_base_dir=/srv/lemmy`: the location on the server where lemmy can be installed, can be any folder
+# if you are upgrading from a previous version, set this to `/lemmy`
myuser@example.com domain=example.com letsencrypt_contact_email=your@email.com lemmy_base_dir=/srv/lemmy
[all:vars]
diff --git a/ansible/lemmy.yml b/ansible/lemmy.yml
index 242d9043..5c8a5f91 100644
--- a/ansible/lemmy.yml
+++ b/ansible/lemmy.yml
@@ -7,7 +7,7 @@
pre_tasks:
- name: check lemmy_base_dir
fail:
- msg: "lemmy_base_dir is unset, old default value was '/lemmy'"
+ msg: "`lemmy_base_dir` is unset. if you are upgrading from an older version, add `lemmy_base_dir=/lemmy` to your inventory file."
when: lemmy_base_dir is not defined
- name: install python for Ansible
diff --git a/ansible/lemmy_dev.yml b/ansible/lemmy_dev.yml
index 1e7369da..e8556665 100644
--- a/ansible/lemmy_dev.yml
+++ b/ansible/lemmy_dev.yml
@@ -7,6 +7,11 @@
# https://www.josharcher.uk/code/ansible-python-connection-failure-ubuntu-server-1604/
gather_facts: False
pre_tasks:
+ - name: check lemmy_base_dir
+ fail:
+ msg: "`lemmy_base_dir` is unset. if you are upgrading from an older version, add `lemmy_base_dir=/lemmy` to your inventory file."
+ when: lemmy_base_dir is not defined
+
- name: install python for Ansible
raw: test -e /usr/bin/python || (apt -y update && apt install -y python-minimal python-setuptools)
args: