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

Create an OVH CRON to run a post command #23

Open
2 tasks
ThomasLdev opened this issue Mar 20, 2024 · 0 comments
Open
2 tasks

Create an OVH CRON to run a post command #23

ThomasLdev opened this issue Mar 20, 2024 · 0 comments
Assignees

Comments

@ThomasLdev
Copy link
Owner

ThomasLdev commented Mar 20, 2024

  • Create an OVH CRON that runs every hour (its the minimal time they have for this plan)
  • The CRON will run a command each time. The command does the following :
  1. For every user, check all tasks.
  2. If a task has match the run conditions, run the task. To match the conditions, a task has to :
  • be active
  • have a media to post (txt is optional)
  • have a task->lastRunnedAt property that is later than the task->postFrequency
    ---(exemple : John creates a task that says : post 1 media + txt on my instagram account every monday at 8pm. The postFrequency will be : 0 18 * * 1. The cron will run the PostCommand every hour, and this command will check if the current date is reached since the lastRunnedAt. If so, it triggers the action.
  1. create detailed logs by task (via TaskLog entity with 1:1 relation) and update task status.
@ThomasLdev ThomasLdev self-assigned this Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant