Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
SlapOS Develop
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
Eric Zheng
SlapOS Develop
Commits
e7628a27
Commit
e7628a27
authored
May 07, 2013
by
Cédric Le Ninivin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Squid use destination ip instead of domain
parent
66789ff2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
slapos/recipe/squid/__init__.py
slapos/recipe/squid/__init__.py
+2
-2
slapos/recipe/squid/template/squid.conf.in
slapos/recipe/squid/template/squid.conf.in
+1
-1
No files found.
slapos/recipe/squid/__init__.py
View file @
e7628a27
...
@@ -41,7 +41,7 @@ class Recipe(GenericBaseRecipe):
...
@@ -41,7 +41,7 @@ class Recipe(GenericBaseRecipe):
cache-path -- location of the cache directory
cache-path -- location of the cache directory
XXXX No good, specific...
XXXX No good, specific...
domain -- domain we want to cache
public_ipv4 -- public ipv4 of the server
ip -- ip of the squid server
ip -- ip of the squid server
...
@@ -69,7 +69,7 @@ class Recipe(GenericBaseRecipe):
...
@@ -69,7 +69,7 @@ class Recipe(GenericBaseRecipe):
access_log_path
=
self
.
options
[
'access-log-path'
],
access_log_path
=
self
.
options
[
'access-log-path'
],
cache_log_path
=
self
.
options
[
'cache-log-path'
],
cache_log_path
=
self
.
options
[
'cache-log-path'
],
pid_filename_path
=
self
.
options
[
'pid-filename-path'
],
pid_filename_path
=
self
.
options
[
'pid-filename-path'
],
domain
=
self
.
options
[
'domain
'
],
public_ipv4
=
self
.
options
[
'public-ipv4
'
],
)
)
template_filename
=
self
.
getTemplateFilename
(
'squid.conf.in'
)
template_filename
=
self
.
getTemplateFilename
(
'squid.conf.in'
)
...
...
slapos/recipe/squid/template/squid.conf.in
View file @
e7628a27
...
@@ -8,7 +8,7 @@ http_port %(ip)s:%(port)s accel defaultsite=%(ip)s
...
@@ -8,7 +8,7 @@ http_port %(ip)s:%(port)s accel defaultsite=%(ip)s
cache_peer %(backend_ip)s parent %(backend_port)s 0 no-query originserver name=backend
cache_peer %(backend_ip)s parent %(backend_port)s 0 no-query originserver name=backend
acl our_sites dst
domain %(domain
)s
acl our_sites dst
%(public_ipv4
)s
http_access allow our_sites
http_access allow our_sites
cache_peer_access backend allow our_sites
cache_peer_access backend allow our_sites
cache_peer_access backend deny all
cache_peer_access backend deny all
...
...
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