Commit 5ce4bdaa authored by Per Buer's avatar Per Buer

Redone for clearity

Also removed some redundant stuff.
parent d114e149
......@@ -12,28 +12,32 @@ file. If you installed from source this is
/usr/local/etc/varnish/default.vcl, if you installed from a package it
is probably /etc/varnish/default.vcl.
Somewhere in the top there will be a section that looks a bit like this.::
If you've been following the tutorial there is probably a section of
the configuration that looks like this:::
# backend default {
# .host = "127.0.0.1";
# .port = "8080";
# }
backend default {
.host = "www.varnish-cache.org";
.port = "80";
}
We comment in this bit of text and change the port setting from 8080
to 80, making the text look like.::
Since you probably don't want to be mirroring varnish-cache.org we
need to get Varnish to fetch content from your own origin
server. We've already bound Varnish to the public port 80 on the
server so now we need to tie it to the origin.
For this example, let's pretend the origin server is running on
localhost, port 8080.
backend default {
.host = "127.0.0.1";
.port = "80";
.port = "8080";
}
Now, this piece of configuration defines a backend in Varnish called
*default*. When Varnish needs to get content from this backend it will
connect to port 80 on localhost (127.0.0.1).
Varnish can have several backends defined and can you can even join
several backends together into clusters of backends for load balancing
purposes.
purposes, having Varnish pick one backend based on different
algorithms.
Now that we have the basic Varnish configuration done, let us start up
Varnish on port 8080 so we can do some fundamental testing on it.
A lot of the power of Varnish Cache comes from it's design, which
might not be what you are expecting. Next, let's have a look at some of
them.
......@@ -6,4 +6,6 @@ Now what?
You've read through the tutorial. You should have Varnish up and
running. You should know about the logs and you should have a rough
idea of what VCL is.
\ No newline at end of file
idea of what VCL is. Next, you might want to have a look at
:ref:``users-guide-index``, where we go through the features of
Varnish in more detail.
......@@ -6,6 +6,15 @@ There are a couple of things that are different with Varnish Cache, as
opposed to other programs. One thing you've already seen - VCL. I'll
just give you a very quick tour of the other pecularities.
Configuration
~~~~~~~~~~~~~
The Varnish Configuration is written in VCL. When Varnish is ran this
configuration is transformed into C code and then fed into a C
compiler, loaded and run. So, as opposed to declaring various
settings, you write polices on how the incomming traffic should be
handled.
varnishadm
~~~~~~~~~~
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment