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

question about trying to use cron-k8s as the image for a Kubernetes CronJob #61

Open
davehorton opened this issue Feb 8, 2018 · 2 comments

Comments

@davehorton
Copy link

davehorton commented Feb 8, 2018

Per the title, I'm using the Dockerfile in cron-k8s to build an image that I then deploy as a k8s CronJob. But, don't we need to actually exec `/opt/homer_mysql_rotate.pl' in run.sh somewhere around here

I'm unclear how it would work otherwise.

@davehorton davehorton changed the title question about trying to use cron-k8s as the image for a Kubernetes cron job question about trying to use cron-k8s as the image for a Kubernetes CronJob Feb 8, 2018
@dougbtv
Copy link
Member

dougbtv commented Feb 8, 2018

Hey Dave -- are you looking at this block in the deploy.yaml?

At the time I wrote that I decided to drop it because it was still an alpha feature, so... I'm unsure where I left off with it, or if I ever had it working, but decided to keep that commented out block for reference.

You're on the right track though -- you should be able to directly use that script and bypass the run. Unless the run.sh does some fancy pants copying of configurations (a kind of... pragmatic work-around in some of these cases).

Should wind up with something in the container spec looking something like...

command: ["/opt/homer_mysql_rotate.pl"]
args: ["--example", "probably_unused"]

If you do figure it out, a PR to bring it back into the repo would be awesome. Thanks!!

@dougbtv
Copy link
Member

dougbtv commented Feb 8, 2018

Alright, I'm reading through more now (like actually reading the file you linked), and.... I think you're right -- that run.sh is missing actually... running the cron job, good eye.

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

2 participants