Saltstack Official Nginx Formula
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

32 linhas
1.1KB

  1. {% set nginx = pillar.get('nginx', {}) -%}
  2. {% set home = nginx.get('home', '/var/www') -%}
  3. {% set source = nginx.get('source_root', '/usr/local/src') -%}
  4. {% set openresty = nginx.get('openresty', {}) -%}
  5. {% set openresty_version = openresty.get('version', '1.2.7.8') -%}
  6. {% set openresty_checksum = openresty.get('checksum', 'sha1=f8bee501529ffec33f9cabc00ea4ca512a8d7b59') -%}
  7. {% set openresty_package = source + '/openresty-' + openresty_version + '.tar.gz' -%}
  8. get-openresty:
  9. file.managed:
  10. - name: {{ openresty_package }}
  11. - source: http://openresty.org/download/ngx_openresty-{{ openresty_version }}.tar.gz
  12. - source_hash: {{ openresty_checksum }}
  13. cmd.wait:
  14. - cwd: {{ source }}
  15. - name: tar -zxf {{ openresty_package }} -C {{ home }}
  16. - watch:
  17. - file: get-openresty
  18. install_openresty:
  19. cmd.wait:
  20. - cwd: {{ home }}/ngx_openresty-{{ openresty_version }}
  21. - names:
  22. - ./configure --with-luajit \
  23. --with-http_drizzle_module \
  24. --with-http_postgres_module \
  25. --with-http_iconv_module
  26. - make && make install
  27. - watch:
  28. - cmd: get-openresty