summarylogtreecommitdiffstats
path: root/aegir-hostmaster.install
blob: 4c677ab4f814f0a289733628d57d726d96d5607f (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
post_install() {
    post_upgrade
    passwd -l aegir &>/dev/null

    echo ">>> 1. Ensure this machine's hostname is a FQDN that resolves one of its IP addresses"
    echo ">>> 2. Init. MariaDB: start mysqld.service and run as root /usr/bin/mysql_secure_installation"
    echo ">>> 3. Create a separate MySQL account for Aegir by running as MySQL root:"
    echo ">>>  # GRANT ALL PRIVILEGES ON *.* TO 'aegir_root'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION;"
    echo ">>> 4. Verify that the smtp-forwarder is working and mail can be sent"
    echo ">>> 4. Start the php-fpm, cron, service units (nginx will start after)"
    echo ">>> 5. Install hostmaster by running as the aegir user:"
    echo ">>>  \$ drush hostmaster-install --web_group=http [--http_service_type=nginx] \\"
    echo ">>>       --root=/usr/share/webapps/aegir [--aegir_db_user=USER --aegir_db_pass=PASS] \\"
    echo ">>>       --aegir_host=FQDN [--client_email=email] FQDN"
    echo ">>> 6. Start the nginx service unit and enable start at boot: php-fpm, nginx, cron, mysqld units."
    echo ">>> 7. Use the provided one-time root user login to log into Aegir's frontend."
}

post_upgrade() {
    # create user/group that the daemon will run as by default, do not delete this on uninstall, as it will own files
    getent group aegir >/dev/null || groupadd aegir
    getent passwd aegir >/dev/null || useradd -g aegir -G http,mail -b '/var/lib' -s /bin/bash aegir

}