Mobile app version of vmapp.org
Login or Join
Ravi8258870

: Help me make a cronjob/screen command please? Hi guys I want to set up a cronjob on reboot to do this cd /home/admin/vivalaminecraft.com && screen -d -m -S mcscreen && mono McMyAdmin.exe

@Ravi8258870

Posted in: #Cron

Hi guys I want to set up a cronjob on reboot to do this

cd /home/admin/vivalaminecraft.com && screen -d -m -S mcscreen && mono McMyAdmin.exe

The issue is when I execute this it seems to create the screen but doesn't do the mono McMyAdmin.exe in the screen...

Is there like a then command ?

so it does 1. then 2. then 3. ?

Could someone please help out :)

So I tried this:

so I did this:
@reboot screen -dmS minecraft @reboot cd /home/admin/vivalaminecraft.com @reboot mono McMyAdmin.exe


It still doesn't work. The screen is created but it doesn't have the mono execution in it

I put this in it

#!/bin/bash

screen -dmS minecraft;
cd /home/admin/vivalaminecraft.com;
mono McMyAdmin.exe;


is this correct?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Ravi8258870

1 Comments

Sorted by latest first Latest Oldest Best

 

@Bryan171

Put the following into your crontab file
@reboot screen -d -m -S mcscreen @reboot mono /home/admin/vivalaminecraft.com/McMyAdmin.exe


Crontabs run through in order from top to bottom, so if things have the exact same time or parameter the top one will run first.

I don't know if mcscreen is a file inside vivilaminecraft.com but if it is then include the absolute path.

If that doesn't work you could try adding a shell script into /etc/init.d/ to run those commands, items in init.d get called during boot up.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme