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

Location ordering #686

Closed
pruchai opened this issue Sep 17, 2015 · 3 comments
Closed

Location ordering #686

pruchai opened this issue Sep 17, 2015 · 3 comments

Comments

@pruchai
Copy link

pruchai commented Sep 17, 2015

Is there any way to order locations in the way they are defined in my hiera yaml file? I am trying to go from static configs and erb templates being pushed to servers to automatically generated configs with this module and hiera, and my virtual host config is a mess! How can i maintain the order of locations?

@cjeanneret
Copy link

I need the same kind of thing. According to the doc, order is important especially for regexp:

[…]the location with the longest matching prefix is selected and remembered. Then regular
expressions are checked, in the order of their appearance in the configuration file. The search of
regular expressions terminates on the first match, and the corresponding configuration is used

source

@cjeanneret
Copy link

Ah, didn't see the $priority parameter for location resource.

Might be cool to order the parameters so that we can find them faster…

@dhoppe
Copy link
Member

dhoppe commented Sep 17, 2016

Hello,

this is a mighty module. I do not think ordering the parameters would change anything. But patches regarding the documentation of this module are always welcome.

https://github.com/voxpupuli/puppet-nginx/blob/master/manifests/resource/location.pp#L90-L92

@dhoppe dhoppe closed this as completed Sep 17, 2016
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

3 participants