Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix the systemctl conditional so it restarts with systemd #2165

Merged
merged 1 commit into from
May 19, 2021
Merged

fix the systemctl conditional so it restarts with systemd #2165

merged 1 commit into from
May 19, 2021

Conversation

algobarb
Copy link
Contributor

Summary

Fix systemctl condition so that it will restart with systemd

Test Plan

# Make changes to cmd/updater/update.sh and add the following:
# cp /home/ubuntu/go-algorand/cmd/updater/update.sh "${UPDATESRCDIR}/bin/${FILENAME}"
# add it above the following line so that the update script doesn't get overwritten while testing.:
# exec "${UPDATESRCDIR}/bin/${FILENAME}" ${INSTALLOPT} -r -c ${CHANNEL} ${DATADIRSPEC} ${NOSTART} ${BINDIRSPEC} ${HOSTEDSPEC} ${GENESIS_NETWORK_DIR_SPEC} ${UNKNOWNARGS[@]}

cd ~/go-algorand && ./scripts/configure_dev.sh
make install
cd /home/ubuntu/go/bin
sudo ./systemd-setup.sh ubuntu ubuntu
sudo systemctl daemon-reload
export ALGORAND_DATA=~/.algorand
sudo systemctl start algorand@$(systemd-escape $ALGORAND_DATA)
sudo systemctl status algorand@$(systemd-escape $ALGORAND_DATA)

curl http://$(cat ~/.algorand/algod.net)/versions # 2.5.4
./algod -v # 2.5.4

./update.sh -u -c stable-tmp -p . -d ~/.algorand
./algod -v # becomes latest 2.5.6 
curl http://$(cat ~/.algorand/algod.net)/versions # remains 2.5.4 without the execstart change but updates to 2.5.6 with the new change
sudo systemctl status algorand@$(systemd-escape $ALGORAND_DATA)

@algojohnlee algojohnlee merged commit 1e14742 into algorand:master May 19, 2021
tsachiherman pushed a commit to tsachiherman/go-algorand that referenced this pull request Jul 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants