Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


    Cloudron Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    Solved CLI and Cron

    PeerTube
    5
    8
    374
    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.
    • L
      LorneG last edited by

      Hey there..

      I'd like to run a cron job that imports videos from a YouTube channel..

      Is cron part of this package? If so, can I use the 'peertube' command as part of a cron job?

      If not, is there a way to get cron up and running?

      Thanks so much for all your efforts.

      Cheers,
      Lorne

      nebulon 1 Reply Last reply Reply Quote 0
      • rmdes
        rmdes @micmc last edited by

        Going to try this out now that cron job is integrated in the app on cloudron side.

        d13e9a95-eb43-418f-8f4b-3cf4ffc18df8-image.png

        micmc 1 Reply Last reply Reply Quote 1
        • nebulon
          nebulon Staff @LorneG last edited by

          @lorneg currently there is no cron running for that app package. I guess we can add that for the next package release.

          What would be your peertube cli command to put into the cron job? Just so we can ensure your use-case is covered correctly then.

          L micmc 2 Replies Last reply Reply Quote 1
          • L
            LorneG @nebulon last edited by

            @nebulon

            Hey mate.. Sorry! I just realised you'd replied.

            I imagine the crontab would look something like this:

            0 2 * * * peertube import -u 'https://XXXXX' -U 'XXXXX' --password 'XXXXX' --target-url 'https://www.youtube.com/channel/XXXXX' --since $(date --date="-1 days" +%Y-%m-%d) --tmpdir /tmp

            Let me know if you see anytihg weird there, or if you need any more info.

            Thanks again!

            1 Reply Last reply Reply Quote 1
            • micmc
              micmc @nebulon last edited by

              @nebulon said in CLI and Cron:

              @lorneg currently there is no cron running for that app package. I guess we can add that for the next package release.

              That would be an excellent idea!
              BTW, can't we just write and run crontab from the CLI on the app terminal interface?

              Andy


              https://marketingtechnology.agency
              For cutting edge web technologies

              1 Reply Last reply Reply Quote 0
              • girish
                girish Staff last edited by

                I think a general way to run cron jobs possibly per app would be useful. I have made a task for the next release - https://git.cloudron.io/cloudron/box/-/issues/793

                micmc 1 Reply Last reply Reply Quote 2
                • micmc
                  micmc @girish last edited by

                  @girish said in CLI and Cron:

                  I think a general way to run cron jobs possibly per app would be useful. I have made a task for the next release - https://git.cloudron.io/cloudron/box/-/issues/793

                  Useful, indeed for non-techie folks because crontab is not obvious at all one is not sysadmin.

                  Andy


                  https://marketingtechnology.agency
                  For cutting edge web technologies

                  rmdes 1 Reply Last reply Reply Quote 0
                  • rmdes
                    rmdes @micmc last edited by

                    Going to try this out now that cron job is integrated in the app on cloudron side.

                    d13e9a95-eb43-418f-8f4b-3cf4ffc18df8-image.png

                    micmc 1 Reply Last reply Reply Quote 1
                    • micmc
                      micmc @rmdes last edited by

                      @rmdes Alright let's see the outcome ! 😆


                      https://marketingtechnology.agency
                      For cutting edge web technologies

                      1 Reply Last reply Reply Quote 0
                      • Topic has been marked as solved  girish girish 
                      • First post
                        Last post
                      Powered by NodeBB