Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
83149f12
Commit
83149f12
authored
Oct 09, 2017
by
Dridi Boukelmoune
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use the correct syntax for RST ``literals``
parent
ecb6e716
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
run_cli.rst
doc/sphinx/users-guide/run_cli.rst
+12
-12
No files found.
doc/sphinx/users-guide/run_cli.rst
View file @
83149f12
...
@@ -3,46 +3,46 @@
...
@@ -3,46 +3,46 @@
CLI - bossing Varnish around
CLI - bossing Varnish around
============================
============================
Once `
varnishd
` is started, you can control it using the command line
Once `
`varnishd`
` is started, you can control it using the command line
interface.
interface.
The easiest way to do this, is using `
varnishadm
` on the
The easiest way to do this, is using `
`varnishadm`
` on the
same machine as `
varnishd
` is running::
same machine as `
`varnishd`
` is running::
varnishadm help
varnishadm help
If you want to run `
varnishadm
` from a remote system, you can do it
If you want to run `
`varnishadm`
` from a remote system, you can do it
two ways.
two ways.
You can SSH into the `
varnishd` computer and run `varnishadm
`::
You can SSH into the `
`varnishd`` computer and run ``varnishadm`
`::
ssh $http_front_end varnishadm help
ssh $http_front_end varnishadm help
But you can also configure `
varnishd
` to accept remote CLI connections
But you can also configure `
`varnishd`
` to accept remote CLI connections
(using the '-T' and '-S' arguments)::
(using the '-T' and '-S' arguments)::
varnishd -T :6082 -S /etc/varnish_secret
varnishd -T :6082 -S /etc/varnish_secret
And then on the remote system run `
varnishadm
`::
And then on the remote system run `
`varnishadm`
`::
varnishadm -T $http_front_end -S /etc/copy_of_varnish_secret help
varnishadm -T $http_front_end -S /etc/copy_of_varnish_secret help
but as you can see, SSH is much more convenient.
but as you can see, SSH is much more convenient.
If you run `
varnishadm
` without arguments, it will read CLI commands from
If you run `
`varnishadm`
` without arguments, it will read CLI commands from
`
stdin
`, if you give it arguments, it will treat those as the single
`
`stdin`
`, if you give it arguments, it will treat those as the single
CLI command to execute.
CLI command to execute.
The CLI always returns a status code to tell how it went: '200'
The CLI always returns a status code to tell how it went: '200'
means OK, anything else means there were some kind of trouble.
means OK, anything else means there were some kind of trouble.
`
varnishadm
` will exit with status 1 and print the status code on
`
`varnishadm`
` will exit with status 1 and print the status code on
standard error if it is not 200.
standard error if it is not 200.
What can you do with the CLI
What can you do with the CLI
----------------------------
----------------------------
The CLI gives you almost total control over `
varnishd
` some of the more important tasks you can perform are:
The CLI gives you almost total control over `
`varnishd`
` some of the more important tasks you can perform are:
* load/use/discard VCL programs
* load/use/discard VCL programs
* ban (invalidate) cache content
* ban (invalidate) cache content
...
@@ -166,7 +166,7 @@ and::
...
@@ -166,7 +166,7 @@ and::
varnish> start
varnish> start
If you start `
varnishd
` with the '-d' (debugging) argument, you will
If you start `
`varnishd`
` with the '-d' (debugging) argument, you will
always need to start the child process explicitly.
always need to start the child process explicitly.
Should the child process die, the master process will automatically
Should the child process die, the master process will automatically
...
...
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