You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi. since I am using my servers for other purposes too, I reboot it frequently, so I made a piece of bash command to create a crontab schedule to start an screen at every startup of my server.
This code creates an screen with name lava and starts the task: screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'
This code is supposed to be added to crontab schedules like this: crontab -e
and adding this to the file and save: @reboot screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'
And this final code automatically adds the above code to crontab schedules all at once: { crontab -l -u root; echo "@reboot screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'"; } | crontab -u root -
The text was updated successfully, but these errors were encountered:
Hi. since I am using my servers for other purposes too, I reboot it frequently, so I made a piece of bash command to create a crontab schedule to start an screen at every startup of my server.
This code creates an screen with name lava and starts the task:
screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'
This code is supposed to be added to crontab schedules like this:
crontab -e
and adding this to the file and save:
@reboot screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'
And this final code automatically adds the above code to crontab schedules all at once:
{ crontab -l -u root; echo "@reboot screen -dmS lava sh -c 'cd /root/lava-farmer/ && go run main.go'"; } | crontab -u root -
The text was updated successfully, but these errors were encountered: