github.com/ethersphere/bee/v2@v2.2.0/packaging/deb/postinst (about) 1 #!/bin/sh -e 2 3 if [ "$1" = "configure" ]; then 4 if [ -z "$2" ]; then 5 # initial installation 6 if [ ! -f /var/lib/bee/keys/libp2p.key ]; then 7 /usr/bin/bee init --config /etc/bee/bee.yaml >/dev/null 8 chown -R bee:bee /var/lib/bee 9 fi 10 echo " 11 Logs: journalctl -f -u bee.service 12 Config: /etc/bee/bee.yaml 13 14 Bee requires a Gnosis Chain RPC endpoint to function. By default this is expected to be found at ws://localhost:8546. 15 16 Please see https://docs.ethswarm.org/docs/installation/install for more details on how to configure your node. 17 18 After you finish configuration run 'sudo bee-get-addr' and fund your node with XDAI, and also XBZZ if so desired. 19 " 20 fi 21 22 deb-systemd-helper unmask bee.service >/dev/null || true 23 24 if deb-systemd-helper --quiet was-enabled bee.service; then 25 deb-systemd-helper enable bee.service >/dev/null || true 26 else 27 deb-systemd-helper update-state bee.service >/dev/null || true 28 fi 29 if [ -d /run/systemd/system ]; then 30 systemctl --system daemon-reload >/dev/null || true 31 # upgrade 32 if [ ! -z "$2" ]; then 33 deb-systemd-invoke start bee.service >/dev/null || true 34 fi 35 fi 36 fi