summaryrefslogtreecommitdiff
path: root/ergo/ergo.install
blob: 26c9ee94660eac053e3425153849f806ec551d51 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Warning: This file has syntactically significant, mixed whitespace.
# The heredoc bodies are indented with tabs up to the block level.
# The tabs are for block indentation in the source code.
# The spaces following the tabs are for indentation of the printed output.

post_install() {
  if [[ -e /var/lib/oragono/ircd.db ]]; then
cat <<-EOF
			==> Oragono is now Ergo, you may want to move the
			    files in /var/lib/oragono to /var/lib/ergo.
EOF
  else
    if [[ ! -e /var/lib/ergo/ircd.db ]]; then
cat <<-EOF
			==> Ergo needs to initialize the database and have
			    certificates made available prior to use.

			cd /var/lib/ergo
			sudo -u ergo /usr/bin/ergo mkcerts --config /etc/ergo.conf
			sudo -u ergo /usr/bin/ergo initdb --config /etc/ergo.conf
EOF
    fi
  fi
}