Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Titouan Soulard
slapos
Commits
6f6aca4d
Commit
6f6aca4d
authored
May 21, 2013
by
Cédric Le Ninivin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
apache-frontend: Small improvments on profile and templates for apache frontend
parent
469f67a8
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
12 deletions
+11
-12
software/apache-frontend/apache-slave-list.cfg.in
software/apache-frontend/apache-slave-list.cfg.in
+6
-7
software/apache-frontend/common.cfg
software/apache-frontend/common.cfg
+1
-1
software/apache-frontend/instance.cfg
software/apache-frontend/instance.cfg
+2
-2
software/apache-frontend/slave-virtualhost.conf.in
software/apache-frontend/slave-virtualhost.conf.in
+2
-2
No files found.
software/apache-frontend/apache-slave-list.cfg.in
View file @
6f6aca4d
...
@@ -20,8 +20,7 @@ context =
...
@@ -20,8 +20,7 @@ context =
template = {{ template_slave_configuration }}
template = {{ template_slave_configuration }}
filename = {{ '%s.conf' % slave_reference }}
filename = {{ '%s.conf' % slave_reference }}
extra-context =
extra-context =
key apache_custom_https {{ 'slave-instance-%s-configuration:custom-https' % slave_reference }}
section slave_parameter {{ 'slave-instance-%s-configuration' % slave_reference }}
key apache_custom_http {{ 'slave-instance-%s-configuration:custom-http' % slave_reference }}
raw https_port {{ https_port }}
raw https_port {{ https_port }}
raw http_port {{ http_port }}
raw http_port {{ http_port }}
{{ '\n' }}
{{ '\n' }}
...
@@ -32,7 +31,7 @@ extra-context =
...
@@ -32,7 +31,7 @@ extra-context =
{% set cert_title = '%s-%s' % (slave_reference, cert_name.replace('ssl_', '')) -%}
{% set cert_title = '%s-%s' % (slave_reference, cert_name.replace('ssl_', '')) -%}
{% set cert_file = '/'.join([custom_ssl_directory, cert_title.replace('-','.')]) -%}
{% set cert_file = '/'.join([custom_ssl_directory, cert_title.replace('-','.')]) -%}
{% do part_list.append(cert_title) -%}
{% do part_list.append(cert_title) -%}
{% do slave_parameter_dict.
update([(cert_name, cert_file)]
) -%}
{% do slave_parameter_dict.
__setitem__(cert_name, cert_file
) -%}
[{{ cert_title }}]
[{{ cert_title }}]
< = jinja2-template-base
< = jinja2-template-base
template = {{ empty_template }}
template = {{ empty_template }}
...
@@ -49,13 +48,13 @@ value = {{ dumps(slave_instance.get(cert_name)) }}
...
@@ -49,13 +48,13 @@ value = {{ dumps(slave_instance.get(cert_name)) }}
[{{ ('slave-instance-%s-configuration' % slave_reference) }}]
[{{ ('slave-instance-%s-configuration' % slave_reference) }}]
{% set apache_custom_http = ((slave_instance.get('apache_custom_http', '')) % slave_parameter_dict) -%}
{% set apache_custom_http = ((slave_instance.get('apache_custom_http', '')) % slave_parameter_dict) -%}
{% set apache_custom_https = ((slave_instance.get('apache_custom_https', '')) % slave_parameter_dict) -%}
{% set apache_custom_https = ((slave_instance.get('apache_custom_https', '')) % slave_parameter_dict) -%}
custom-
http = {{ dumps(apache_custom_http) }}
apache_custom_
http = {{ dumps(apache_custom_http) }}
custom-
https = {{ dumps(apache_custom_https) }}
apache_custom_
https = {{ dumps(apache_custom_https) }}
{{ '\n' }}
{{ '\n' }}
# The slave use cache
# The slave use cache
{% if 'enable_cache' in slave_instance and 'url' in slave_instance and 'server_name' in slave_instance -%}
{% if 'enable_cache' in slave_instance and 'url' in slave_instance and 'server_name' in slave_instance -%}
{% do cached_server_dict.
update([(slave_instance.get('server_name'), slave_instance.get('url'))]
) -%}
{% do cached_server_dict.
__setitem__(slave_instance.get('server_name'), slave_instance.get('url')
) -%}
{% endif -%}
{% endif -%}
{% endfor -%}
{% endfor -%}
...
...
software/apache-frontend/common.cfg
View file @
6f6aca4d
software/apache-frontend/instance.cfg
View file @
6f6aca4d
...
@@ -302,12 +302,12 @@ wrapper-path = $${directory:service}/squid-reload
...
@@ -302,12 +302,12 @@ wrapper-path = $${directory:service}/squid-reload
[frontend-apache-graceful]
[frontend-apache-graceful]
recipe = slapos.cookbook:wrapper
recipe = slapos.cookbook:wrapper
command-line = ${buildout:bin-directory}/killpidfromfile $${apache-configuration:pid-file} SIGUSR1
command-line = ${buildout:bin-directory}/killpidfromfile $${apache-configuration:pid-file} SIGUSR1
wrapper-path = $${directory:
service
}/frontend-apache-graceful
wrapper-path = $${directory:
run
}/frontend-apache-graceful
[cached-apache-graceful]
[cached-apache-graceful]
recipe = slapos.cookbook:wrapper
recipe = slapos.cookbook:wrapper
command-line = ${buildout:bin-directory}/killpidfromfile $${apache-configuration:cache-pid-file} SIGUSR1
command-line = ${buildout:bin-directory}/killpidfromfile $${apache-configuration:cache-pid-file} SIGUSR1
wrapper-path = $${directory:
service
}/cached-apache-graceful
wrapper-path = $${directory:
run
}/cached-apache-graceful
[promise-apache-frontend-v4-https]
[promise-apache-frontend-v4-https]
recipe = slapos.cookbook:check_port_listening
recipe = slapos.cookbook:check_port_listening
...
...
software/apache-frontend/slave-virtualhost.conf.in
View file @
6f6aca4d
<VirtualHost *:{{ https_port }}>
<VirtualHost *:{{ https_port }}>
{{
apache_custom_https
}}
{{
slave_parameter.get('apache_custom_https','')
}}
</VirtualHost>
</VirtualHost>
<VirtualHost *:{{ http_port }}>
<VirtualHost *:{{ http_port }}>
{{
apache_custom_http
}}
{{
slave_parameter.get('apache_custom_http','')
}}
</VirtualHost>
</VirtualHost>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment