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

How to execute rake command as cronjob #202

Closed
HigH-HawK opened this issue May 6, 2020 · 1 comment
Closed

How to execute rake command as cronjob #202

HigH-HawK opened this issue May 6, 2020 · 1 comment

Comments

@HigH-HawK
Copy link

Hi,

we are using the latest Redmine Docker Container from (https://hub.docker.com/_/redmine) with a docker-compose.yml file and want to setup issue creation via IMAP email retrieval.

When I access the redmine container via

docker exec -it redmine /bin/bash

and execute the rake command

bundle exec rake redmine:email:receive_imap RAILS_ENV="production" host=imap.gmail.com port=993 username=username password=password ssl=true folder="IMAPFolder" unknown_user=accept no_permission_check=1 project="myRedmineProjectIdentifier" tracker=Protocol

It processes the email and creates an issue in Redmine. Now I want to setup a Cronjob, which will be run every 5 minutes to check the IMAP Mailbox and create an issue in Redmine. I am however stuck, as I don't really know how I could setup the Cronjob.

The container itself has no Cron installed and many people were saying that Cronjobs should be run outside of the container and that is where I am stuck, since I don't really know how to realise this.

I found this guide, which kind of explains how to setup something like a Cronjob but am unsure if this works with our container.

Please could someone help me with this?

@HigH-HawK
Copy link
Author

Sorted it with the first post at #64

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