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

upstream_cfg_prepend not working for hash keys without values (ip_hash, least_conn) #425

Closed
aamerik opened this issue Aug 25, 2014 · 2 comments

Comments

@aamerik
Copy link

aamerik commented Aug 25, 2014

Hi,

I'm not able to follow your example:

$backend_members = [ 'rtm001:8901', 'rtm002:8901' ]

$upstream_config = {
    'least_conn' => '',
}

nginx::resource::upstream { 'proxypass':
    ensure => present,
    members => $backend_members,
    upstream_cfg_prepend => $upstream_config,
}

The result in NGINX is (least_conn; is missing)

upstream proxypass {

server rtm001:8901 fail_timeout=10s;
server rtm002:8901 fail_timeout=10s;
}

Please help ;)

@b4ldr
Copy link
Member

b4ldr commented Aug 26, 2014

this was discussed in irc so i thought i would add comments here

_rc> fubada: balder: in 1.9 Array("") -> [""], in 1.8 Array("") -> []
balder: fubada: so the inner iteration
https://github.com/jfryman/puppet-nginx/blob/master/templates/conf.d/upstream_header.erb#L8
doesn't do what is expected under 1.8

_rc>| fubada: so actually the module says you need 1.9.3
https://github.com/jfryman/puppet-nginx#requirements

@aamerik
Copy link
Author

aamerik commented Aug 26, 2014

Confirmed working with ruby 193

@aamerik aamerik closed this as completed Aug 26, 2014
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