summarylogtreecommitdiffstats
path: root/tezos-mainnet-git.install
blob: 8ac35344a82b7156b5f243cec07b81323373b420 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
post_upgrade() {
    if [ ! -d "/usr/share/tezos" ]; then
        echo "Creating directory /usr/share/tezos..."
        mkdir -p -m755 /usr/share/tezos
        chown tezos:tezos /usr/share/tezos
    fi
    if [ ! -f "/usr/share/tezos/.tezos-node/identity.json" ]; then
        echo -e "To create a tezos node identity, run\n"
        echo -e "    $ sudo -u tezos tezos-node identity generate\n"
    else
        echo ""
    fi
    echo -e "To start the tezos node on localhost, run\n"
    echo -e "    $ sudo systemctl start tezos-node\n"
    echo -e "To automatically start it on system start:\n"
    echo -e "    $ sudo systemctl enable tezos-node\n"
}

post_install() {
    post_upgrade
}