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

Extend documentation (fixes #449) #453

Merged
merged 4 commits into from
Apr 18, 2022
Merged

Conversation

hartwork
Copy link
Owner

CC @floari

@hartwork hartwork force-pushed the issue-449-extend-documentation branch from 06c5b6d to a66fbd4 Compare April 11, 2022 20:25
@floari
Copy link

floari commented Apr 13, 2022

Envs are perfect now, thanks.
But still there should be some words about the cron container:

cron:
image: ${COMPOSE_PROJECT_NAME:-jawanndenn}_jawanndenn
command: ["sh", "-c", "supercronic -sentry-dsn "${JAWANNDENN_SENTRY_DSN}" ~/crontab"]

I personally never used sentry or supersonic, maybe the documentation can explain if this part is needed or how to deploy it in a more general way?

@hartwork
Copy link
Owner Author

Envs are perfect now, thanks.

@floari cool!

But still there should be some words about the cron container:

cron: image: ${COMPOSE_PROJECT_NAME:-jawanndenn}_jawanndenn command: ["sh", "-c", "supercronic -sentry-dsn "${JAWANNDENN_SENTRY_DSN}" ~/crontab"]

I personally never used sentry or supersonic, maybe the documentation can explain if this part is needed or how to deploy it in a more general way?

Sentry is completely optional and passing an empty value there should work fine. Sentry is to collect backtraces and to send alerts for server side failures.
Without the cron container, polls that were created to live for say a week will live forever and hence there is a risk of e.g. the database growing too large and for unwanted content to be served for longer. Are you familiar with the general concept of cron and a crontab file?
Please let me know if anything else about the cron container remains unclear.

@hartwork
Copy link
Owner Author

@floari PS: Please relaborate on "how to deploy it in a more general way", I'm not sure I get that part, yet.

@floari
Copy link

floari commented Apr 14, 2022

No problems - maybe wrong phrasing from my side. I meant without using some of the tools you are using (sentry, supercron). With sentry optional this leaves us only with the cron. I did some reading on supercron and of course i know a cron ;)
If I dont want to use supercron, maybe we can just setup the crontab file in the container within the docker-compose? I guess the file which needs to run is: prune_expired_polls.py ?

@hartwork
Copy link
Owner Author

No problems - maybe wrong phrasing from my side. I meant without using some of the tools you are using (sentry, supercron). With sentry optional this leaves us only with the cron. I did some reading on supercron and of course i know a cron ;) If I dont want to use supercron, maybe we can just setup the crontab file in the container within the docker-compose? I guess the file which needs to run is: prune_expired_polls.py ?

Why would you want to avoid supercronic, what issue with the current setup are you trying to solve? That's the job, yes, see crontab entry

@hourly python3 -m django prune_expired_polls

@floari
Copy link

floari commented Apr 14, 2022

To be honest I just have no idea how supercron works - and I have to have it installed beforehand right?

Sorry for my stupid questions, I am currently learning the docker stuff ;)

@hartwork
Copy link
Owner Author

To be honest I just have no idea how supercron works - and I have to have it installed beforehand right?

No, it's running inside the container. And it should work out of the box.

Sorry for my stupid questions, I am currently learning the docker stuff ;)

No worries.

@hartwork
Copy link
Owner Author

@floari PS: Supercronis is installed into the image at

supercronic@edge-community

@hartwork
Copy link
Owner Author

@floari I'll merge this pull request now. Please don't understand that as ending this discussion: We can talk and fix more. Merging now...

@hartwork hartwork merged commit 70704ea into master Apr 18, 2022
@hartwork hartwork deleted the issue-449-extend-documentation branch May 3, 2022 18:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants