• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

Dropbox-Uploader: how to synchronize a folder with cron job?

Scheduled Pinned Locked Moved Troubleshooting
11 Posts 3 Posters 2.6k Views 3 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Away
    sdetweil @MajorC
    last edited by Oct 7, 2020, 8:36 PM

    @MajorC which part of the ‘when the pi boots’ are u having trouble with

    if you use pm2, you can start your script with pm2

    pm2 start scriptpath
    pm2 save

    Sam

    How to add modules

    learning how to use browser developers window for css changes

    M 1 Reply Last reply Oct 9, 2020, 3:28 PM Reply Quote 0
    • M Offline
      MajorC Project Sponsor @sdetweil
      last edited by Oct 9, 2020, 3:28 PM

      @sdetweil can you give me a little bit more details? I am quite new to the MM-world and have no idea where I can find what you wrote?!?

      S 2 Replies Last reply Oct 9, 2020, 3:31 PM Reply Quote 0
      • S Away
        sdetweil @MajorC
        last edited by Oct 9, 2020, 3:31 PM

        @MajorC YOU have to enter those commands

        you said you have a script that will download files

        now, turn it into something that happens every hour, add a while loop around it…
        (I know you don’t know, so google searching will teach you a ton)

        then, once THAT works, you can use the pm2 process manager to launch it for you

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 Reply Last reply Reply Quote 0
        • S Away
          sdetweil @MajorC
          last edited by Oct 9, 2020, 3:34 PM

          @MajorC you said
          But I would like to have a script to do that every time the pi starts up automatically

          so, what commands would you issue to do that

          creating a script is as simple as writing a file with this commands
          making it executable (see chmod command)
          and then launching it.

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          M 1 Reply Last reply Oct 9, 2020, 3:35 PM Reply Quote 0
          • M Offline
            MajorC Project Sponsor @sdetweil
            last edited by Oct 9, 2020, 3:35 PM

            @sdetweil the script is running fine if I start it manualy by hand.

            I need a hint how to do it the same way, the MagicMirror starts.

            S 1 Reply Last reply Oct 9, 2020, 3:36 PM Reply Quote 0
            • S Away
              sdetweil @MajorC
              last edited by sdetweil Oct 9, 2020, 3:37 PM Oct 9, 2020, 3:36 PM

              @MajorC i wrote the two commands u need to issue

              pm2 start scriptpath (where is your script and what is its name, = scriptpath)
              pm2 save
              

              to set it up if you use pm2 to launch MM (which my install script does for you if you used it)

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              M 1 Reply Last reply Oct 9, 2020, 6:17 PM Reply Quote 0
              • M Offline
                MajorC Project Sponsor @sdetweil
                last edited by Oct 9, 2020, 6:17 PM

                @sdetweil thank you. It seams to work. The script was way more easy than expected.

                May I ask, if I roboot the MM with Strg+Q, will my script run again?

                S 1 Reply Last reply Oct 9, 2020, 6:26 PM Reply Quote 0
                • S Away
                  sdetweil @MajorC
                  last edited by sdetweil Oct 10, 2020, 3:23 AM Oct 9, 2020, 6:26 PM

                  @MajorC yes.pm2 reruns regardless how the system was rebooted

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 Reply Last reply Reply Quote 0
                  • 1
                  • 2
                  • 1 / 2
                  1 / 2
                  • First post
                    8/11
                    Last post
                  Enjoying MagicMirror? Please consider a donation!
                  MagicMirror created by Michael Teeuw.
                  Forum managed by Sam, technical setup by Karsten.
                  This forum is using NodeBB as its core | Contributors
                  Contact | Privacy Policy