Skip to content
This repository was archived by the owner on Oct 11, 2022. It is now read-only.

Commit b4a9c2e

Browse files
committed
Update formula to support NGINX mainline repository
1 parent a6f599f commit b4a9c2e

File tree

3 files changed

+15
-16
lines changed

3 files changed

+15
-16
lines changed

CHANGELOG.rst

+2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
zendserver formula
22
================
33

4+
0.1.6 (05-02-2016)
5+
- Added NGINX Mainline support to the repo
46

57
0.1.5 (19-03-2015)
68
- Added extension management

pillar.example

+3
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ zendserver:
1616
# separate users
1717
enable_itk: False
1818

19+
# Whether to use the nginx mainline repo or default stable
20+
nginx_mainline: False
21+
1922
# Whether to bootstrap the Zend Server, otherwise you'll be
2023
# asked to do so when you login to the ZendServer admin page.
2124
bootstrap: False

zendserver/repo/nginx.sls

+10-16
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,22 @@
1+
# Install Nginx repository
2+
{%- set repo_url = 'http://nginx.org/packages' %}
3+
14
{%- set lsb_codename = salt['grains.get']('oscodename') %}
25
{%- set lsb_distrib_id = salt['grains.get']('lsb_distrib_id') %}
3-
# Install Nginx repository
6+
7+
# Handle mainline switch
8+
{%- if salt['pillar.get']('zendserver:nginx_mainline', False) %}
9+
{%- set repo_url = repo_url ~ '/mainline' %}
10+
{%- endif %}
411

512
nginx_repo:
613
pkgrepo.managed:
714
- humanname: Nginx PPA
8-
{%- if lsb_distrib_id == 'Debian' %}
9-
- dist: {{ lsb_codename }}
10-
- name: deb http://nginx.org/packages/debian/ {{ lsb_codename }} nginx
11-
{%- elif lsb_distrib_id == 'Ubuntu' %}
12-
{%- if lsb_codename == 'vivid' %}
13-
- name: deb http://nginx.org/packages/ubuntu/ utopic nginx
14-
- dist: utopic
15-
{%- else %}
16-
- name: deb http://nginx.org/packages/ubuntu/ {{ lsb_codename }} nginx
17-
- dist: {{ lsb_codename }}
18-
{%- endif %}
19-
{%- else %}
20-
- dist: {{ lsb_codename }}
21-
- name: deb http://nginx.org/packages/{{ lsb_distrib_id }}/ {{ lsb_codename }} nginx
22-
{%- endif %}
15+
- name: deb {{ repo_url }}/{{ lsb_distrib_id }}/ {{ lsb_codename }} nginx
2316
- file: /etc/apt/sources.list.d/nginx.list
2417
- keyid: 7BD9BF62
2518
- key_url: http://nginx.org/keys/nginx_signing.key
2619
- keyserver: keyserver.ubuntu.com
2720
- require_in:
2821
- pkg: nginx
22+
- clean_file: True

0 commit comments

Comments
 (0)