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

allow to trigger initial generation immediately #1

Closed
leoschweizer opened this issue Oct 7, 2016 · 4 comments
Closed

allow to trigger initial generation immediately #1

leoschweizer opened this issue Oct 7, 2016 · 4 comments

Comments

@leoschweizer
Copy link

First of all, let me say thanks for this great project, I'm trying to build an auto-configuring Traefik setup with it.

Suppose there are already some containers running and my container with rancher-gen is not the first to start. However, rancher-gen is supposed to generate the configuration file for my reverse proxy in order to route traffic to containers based on the host names of the requests.

It looks like rancher-gen currently does not trigger immediately when it is invoked, but only when Rancher reports some changes. So I would now have to wait for some change in Rancher before any configuration gets generated, which is not really acceptable. I think I need some capability to trigger an initial generation run.

What do you think?

@alejom99
Copy link
Member

alejom99 commented Oct 7, 2016

If you specify the --stack and --service options, rancher-gen will automatically trigger the first time it runs, and every time there's a change in that service. Did you specify those two options?

@leoschweizer
Copy link
Author

@alejom99 no, I did not, because I'm interested in all stacks and services of an environment. So passing these options seems counterproductive 😉

@alejom99
Copy link
Member

alejom99 commented Oct 7, 2016

That was not the intended functionality, but I just released a new version (v0.2.0) where all container instances in the environment will be passed to the template if no filter is specified. Hopefully, this will address you issue.

@leoschweizer
Copy link
Author

👍 awesome! Looks like this solves #2 as well.

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