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

dont deploy "ssl on" on nginx 1.15 or newer #1225

Merged
merged 1 commit into from
Jul 7, 2018

Conversation

bastelfreak
Copy link
Member

fixes #1224. the option 'ssl on' within a server block is deprecated since nginx 1.15.0.

Pull Request (PR) description

This Pull Request (PR) fixes the following issues

@bastelfreak bastelfreak changed the title \o/dont deploy "ssl on" on nginx 1.15 an newer dont deploy "ssl on" on nginx 1.15 or newer Jul 7, 2018
@bastelfreak bastelfreak added the bug Something isn't working label Jul 7, 2018
@@ -121,5 +121,13 @@
$sites_available_group = $_module_parameters['root_group']
$sites_available_mode = '0644'
$super_user = true
if fact('nginx_version') {
$add_listen_directive = versioncmp(fact('nginx_version'), '1.15.0') ? {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this equal to $add_listen_directive = versioncmp(fact('nginx_version'), '1.15.0') < 0?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I has some issues in the past with versioncmp() when the first param is undef, that's why I wrapped it within the if statement.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I meant the ? { ...} part. The full oneliner would be $add_listen_directive = !fact('nginx_version') or versioncmp(fact('nginx_version'), '1.15.0') < 0 but that's not really readable.

fixes voxpupuli#1224. the option 'ssl on' within a server block is deprecated since nginx 1.15.0.
@bastelfreak bastelfreak merged commit 6be6f01 into voxpupuli:master Jul 7, 2018
@bastelfreak bastelfreak deleted the ssl branch July 7, 2018 14:16
Rubueno pushed a commit to Rubueno/puppet-nginx that referenced this pull request Oct 19, 2020
dont deploy "ssl on" on nginx 1.15 or newer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[warn] the "ssl" directive is deprecated, use the "listen ... ssl" directive instead
4 participants