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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
slapos
Commits
9cfb2578
Commit
9cfb2578
authored
Nov 13, 2017
by
Eteri
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
caddy: add bind to a specific ip
parent
09f2f83b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
1 deletion
+13
-1
stack/caddy/Caddyfile.in
stack/caddy/Caddyfile.in
+12
-0
stack/caddy/buildout.cfg
stack/caddy/buildout.cfg
+1
-1
No files found.
stack/caddy/Caddyfile.in
View file @
9cfb2578
...
@@ -10,6 +10,8 @@ tls {{ custom_cert_dict['cert-file'] }} {{ custom_cert_dict['key-file'] }} {
...
@@ -10,6 +10,8 @@ tls {{ custom_cert_dict['cert-file'] }} {{ custom_cert_dict['key-file'] }} {
log {{caddy_configuration_dict['access_log']}}
log {{caddy_configuration_dict['access_log']}}
errors {{caddy_configuration_dict['error_log']}}
root {{ directory_dict['public_html'] }}
root {{ directory_dict['public_html'] }}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
...
@@ -18,6 +20,8 @@ basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
...
@@ -18,6 +20,8 @@ basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
}
}
bind {{caddy_configuration_dict['ipv6']}}
{%- endif %}
{%- endif %}
[{{caddy_configuration_dict['ipv6']}}]:{{parameter_dict['port-ipv6']}} {
[{{caddy_configuration_dict['ipv6']}}]:{{parameter_dict['port-ipv6']}} {
...
@@ -30,22 +34,30 @@ basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
...
@@ -30,22 +34,30 @@ basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
log {{caddy_configuration_dict['access_log']}}
log {{caddy_configuration_dict['access_log']}}
errors {{caddy_configuration_dict['error_log']}}
root {{ directory_dict['public_html'] }}
root {{ directory_dict['public_html'] }}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
{%- endif %}
{%- endif %}
bind {{caddy_configuration_dict['ipv6']}}
}
}
[{{caddy_configuration_dict['local_ip']}}]:{{parameter_dict['port-ipv4']}} {
[{{caddy_configuration_dict['local_ip']}}]:{{parameter_dict['port-ipv4']}} {
log {{caddy_configuration_dict['access_log']}}
log {{caddy_configuration_dict['access_log']}}
errors {{caddy_configuration_dict['error_log']}}
root {{ directory_dict['public_html'] }}
root {{ directory_dict['public_html'] }}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
{% if parameter_dict['enable-basic-auth'] == 'true' -%}
basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
basicauth / {{ parameter_dict['username'] }} {{parameter_dict['password']}}
{%- endif %}
{%- endif %}
bind {{caddy_configuration_dict['local_ip']}}
}
}
\ No newline at end of file
stack/caddy/buildout.cfg
View file @
9cfb2578
...
@@ -27,7 +27,7 @@ mode = 0644
...
@@ -27,7 +27,7 @@ mode = 0644
[template-caddyfile]
[template-caddyfile]
recipe = slapos.recipe.build:download
recipe = slapos.recipe.build:download
url = ${:_profile_base_location_}/Caddyfile.in
url = ${:_profile_base_location_}/Caddyfile.in
#md5sum = bb3b314ebeb58e9875d547a053a9f268
md5sum = 88c4c33e374ea3f61cdd36b2816d24ba
filename = Caddyfile.in
filename = Caddyfile.in
location = ${buildout:parts-directory}/${:_buildout_section_name_}
location = ${buildout:parts-directory}/${:_buildout_section_name_}
mode = 0644
mode = 0644
...
...
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