Commit graph

34 commits

Author SHA1 Message Date
Phil Friderici
c849c2cb7d Add parameter to allow setting error_log severity level 2015-11-01 13:14:08 +00:00
Matthew Haughton
35577ccc88 add remaining gzip directives
Closes #367
2015-07-11 17:07:56 -04:00
John Daniels
310ed828c2 Adjusted tests for proxy variables. 2015-06-15 10:03:27 -04:00
Geoff Garside
27334c1bd4 Manage the nginx log directory.
Ensure the nginx::config::log_dir exists so that the access.log and error.log can be created. Also any nginx::vhost also put their access/error logs in this directory as well. This is done so that on platforms where /var/log/nginx is not created by package installation it exists so that nginx can startup and create the log files.

When vhost purge is enabled the log directory will not be touched and the log files will remain.
2015-06-03 20:43:52 +01:00
Matthew Haughton
8fc4044162 spec: add some more nginx.conf tests 2015-05-08 08:36:42 -04:00
Matthew Haughton
0cd258b310 Merge pull request #590 from 3flex/540-refine-worker_processes-validation
config: refined worker_processes validation
2015-04-10 12:00:44 -04:00
Matthew Haughton
810d36d3a8 config: refined worker_processes validation
Closes #540
2015-04-01 23:34:31 -04:00
Matthew Haughton
faa974b745 spec/Gemfile: switch to rspec-puppet 2
The big win is that it's now possible to test the future parser with the
latest Puppet release. In the past it wasn't possible to test future parser
with anything higher than 3.5.x.
2015-03-30 23:39:50 -04:00
Prachetas Prabhu
409f8ef4e3 Adds rspec tests for nginx_cfg_prepend 2015-03-04 23:55:30 +00:00
Matthew Haughton
be30b57531 Merge pull request #531 from ckaenzig/optional-proxy-http-version
Allow disabling proxy_http_version directive
2014-12-18 10:08:52 -05:00
Christian Kaenzig
6a4e4b4e73 Disable proxy_http_version directive by default
The default value in nginx::config was the same as nginx's default,
so it's not necessary to be set in any version of nginx unless one
needs a specific value. This also allows us to use undef when we don't
want the directive to be set instead of false.

Also added a test for the default case.
2014-12-18 11:22:44 +01:00
Matthew Haughton
bbbb1ca130 Merge pull request #519 from 3flex/refactor-packages
Clean up package classes, allow installing mainline upstream packages
2014-12-14 21:25:56 -05:00
Sergio Ballesteros
1e3bf2fe88 Added test: arrays as values in http_cfg_append 2014-12-11 16:41:47 +01:00
Matthew Haughton
1898182c6d spec: cleanup
* Removed some tests that no longer apply and/or are redundant
* Only set OS facts when testing OS-specific behaviors. This simplifies the
  facts that must be set in the specs and saves running the same tests
  several times when the results wouldn't differ by OS anyway.
2014-12-09 19:47:05 -05:00
Matthew Haughton
9647d1278f add negative test for log_format 2014-12-03 23:26:19 -05:00
Joshua B. Bussdieker
2e221a7e0f Support specifying log formats 2014-12-03 23:26:10 -05:00
James Fryman
4c5f1e3b2a pass one of spec cleanup 2014-09-20 18:25:24 -05:00
Carl P. Corliss
fb880576a6 cleanup resultant whitespace and key/value alignment in config files
- fix tests related to whitespace changes
2014-09-13 04:13:18 -04:00
Matthew Haughton
32bc360d45 Convert specs to RSpec 2.99.1 syntax with Transpec
This conversion is done by Transpec 2.3.4 with the following command:
    transpec -c "rake spec" spec/classes/ spec/defines/ spec/spec_helper.rb

* 210 conversions
    from: it { should ... }
      to: it { is_expected.to ... }

* 19 conversions
    from: it { should_not ... }
      to: it { is_expected.not_to ... }

* 15 conversions
    from: == expected
      to: eq(expected)

* 15 conversions
    from: obj.should
      to: expect(obj).to

For more details: https://github.com/yujinakayama/transpec#supported-conversions
2014-07-17 22:28:38 -04:00
Motiejus Jakštys
0a1dacf605 Allow using $http_cfg_append with list of lists
It should be possible to include array of arrays in order to have
duplicate configuration keys (when permitted), like:

    nginx::http_cfg_append:
        - [include, /etc/nginx/vhosts/*.ngx]
        - [include, /etc/nginx/vhosts/*/*.ngx]
2014-07-01 06:35:20 +02:00
James Fryman
473ed04463 Merge pull request #354 from janorn/temp_paths
Add client_body_temp_path and proxy_temp_path to proxy.conf.
2014-06-24 09:27:18 -05:00
Jan Örnstedt
65c90f1999 Added tests for
pid
http_tcp_nodelay
http_tcp_nopush
keepalive_timeout
2014-06-24 01:41:22 +02:00
Jan Örnstedt
ebd2a6a608 Add client_body_temp_path and proxy_temp_path to proxy.conf. 2014-06-24 00:33:56 +02:00
Lee Packham
8eb26b792b Fix all rspec tests so they run
For some reason these have been broken forever. Travis was failing,
correctly. I have updated the tests to be correct to how the code
actually works.

I would also suggest that if this is merged, we stop merging PRs that
have failed test runs. Tests matter in a module like this.
2014-06-10 22:10:00 +01:00
Daniel Kerwin
04b6c3dd7d Test worker_rlimit_nofile 2014-03-12 18:41:03 +01:00
Zdenek Janda
58818b3a44 Ensure that vhosts are purged with new parameter purge_vhost 2014-03-07 22:18:10 +01:00
Matthew Haughton
58b5f52685 more stringent tests for config file resources 2013-12-08 16:54:25 -05:00
Matthew Haughton
26d904c946 use new 'without_content' matcher 2013-12-08 16:54:20 -05:00
Matthew Haughton
36319cd5e0 set default facts for all manifests 2013-12-07 13:39:24 -05:00
Matthew Haughton
db68cf39ae include_class is deprecated 2013-12-07 13:39:24 -05:00
Matthew Haughton
390b491cc1 ruby 1.8.7 syntax fix 2013-12-02 14:01:38 -05:00
Matthew Haughton
2ccd399a74 add tests to check file fragments are absent 2013-12-02 13:58:23 -05:00
Matthew Haughton
eb31df40d6 Remove vhost and mailhost vhost_autogen.conf
Don't generate it anymore, and remove any existing file from
people's systems
2013-11-30 21:24:55 -05:00
Matthew Haughton
962fa6672a rspec tests for v0.0.6
Resolves #65
2013-11-21 22:14:00 -05:00