Comments (11)
I actually figured this one out. Because the LWRP only sets node variables and doesn't generate a conf.d style file (HAProxy doesn't support that), you have to call all of your LWRPs first then make sure you run the haproxy::default
recipe after all your LWRPs have been run. This means you can't include_recipe 'haproxy'
at the top of your recipes either. In order to make it pull in haproxy but no generate the config, do include_recipe 'haproxy::YOURINSTALLMETHOD'
.
This reallly should be documented.
from haproxy.
I have this same issue, but the log line doesn't fix it for me.
The haproxy_lb just doesn't seem to do anything at all once I've disable the default http servers.
Chef 11.8.2 using chef server.
from haproxy.
Yeah this was frustrating to find. I tried v1.6.2, v1.6.0 and 1.5.0 and it was always the same.
This is on Chef 11.10
from haproxy.
The LWRP and cookbook implementations are buggy. The resource definitions in this case of course should precede the actual haproxy::default recipe include)
There's lazy attribute evaluation and there are also many more ways to to fix this race condition. The result of a good library cookbook must not rely on the run_list recipes order.
There's nothing to document, it's better the cookbook is fixed.
from haproxy.
@remkade's solution worked for me. Running the LWRPs before running the haproxy (default for me) recipe fixes this. My wrapper worked perfectly in vagrant with chef-solo, went to a real box and it broke here.
from haproxy.
@dennybaa From what I understand this is more of a drawback of HAProxy, since you can't currently do a proxy.d/*.conf
style include, which is really the way chef is best equipped to do this. Because of that it ought to be documented since there isn't likely to be a fix anytime soon. I'll submit a pull request.
from haproxy.
Taking a big crack right now at making this cookbook more functional. I've struggled with this cookbook myself in many configuration scenarios. https://github.com/slyness/haproxy/compare/refactor
Hopefully we'll release a more usable cookbook soon.
Note: default.rb will be a noop recipe soon with other function recipes to supply main functionality but with the intention that it can also be used as a resource cookbook to drive wrapper cookbook custom configuration.
from haproxy.
@slyness: is this still our top priority for cookbook maintenance? Will you have time for this this week?
from haproxy.
@calebhailey This particular change set has definitely fallen off my immediate to do list. But I am willing to get back at it. I'll review the current state of things this week.
from haproxy.
I'm going to close this off now as we're working towards a custom resources rewrite.
If #164 doesn't meet your needs we'd love your feedback.
from haproxy.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
from haproxy.
Related Issues (20)
- Multiple bind lines are joined with extraneous colon HOT 11
- conf_cookbook not used in all resources HOT 1
- Leaves server unstable in very specific chef-run failure HOT 2
- Unable to upgrade to v8.1 HOT 2
- Would like to not set stats: "{ 'uri' => '/haproxy-status' }" in resources/config_defaults.rb? HOT 2
- Dangerfile should use failure instead of fail HOT 1
- Remove .rubocop.yml with Dangerfile HOT 1
- Update Changelog HOT 2
- Run latest cookstyle HOT 1
- Update builds to be parallel HOT 1
- Remove foodcritic files
- Haproxy frontend attributes are not showing up HOT 1
- Create Integration for haproxy 2.1 with fastcgi resource, and default install.
- When multiple of same resource are defined, spacing is off
- haproxy Chef-17 compatability
- haproxy_listen resource should have option param
- Source installation fails on Ubuntu 22.04 & Fedora
- Dependency Dashboard
- Update versions
- OpenSSL doesn't compile correctly in the OpenSSL test suite
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from haproxy.