From 61d814e69cf8376ab0575b3fb73f4b94989e403a Mon Sep 17 00:00:00 2001 From: Seth Vargo Date: Tue, 4 Apr 2017 12:40:53 -0400 Subject: [PATCH] Rename sidebar link items --- website/source/docs/install/index.html.md | 73 +++++++++++++++++++ .../getting-started/install.html.markdown | 47 ++++-------- website/source/layouts/docs.erb | 16 ++-- 3 files changed, 98 insertions(+), 38 deletions(-) create mode 100644 website/source/docs/install/index.html.md diff --git a/website/source/docs/install/index.html.md b/website/source/docs/install/index.html.md new file mode 100644 index 0000000000..07dda7b5de --- /dev/null +++ b/website/source/docs/install/index.html.md @@ -0,0 +1,73 @@ +--- +layout: "docs" +page_title: "Install Consul" +sidebar_current: "docs-install-install" +description: |- + Installing Consul is simple. You can download a precompiled binary or compile + from source. This page details both methods. +--- + +# Install Consul + +Installing Consul is simple. There are two approaches to installing Consul: + +1. Using a [precompiled binary](#precompiled-binaries) + +1. Installing [from source](#compiling-from-source) + +Downloading a precompiled binary is easiest, and we provide downloads over TLS +along with SHA256 sums to verify the binary. We also distribute a PGP signature +with the SHA256 sums that can be verified. + +## Precompiled Binaries + +To install the precompiled binary, [download](/downloads.html) the appropriate +package for your system. Consul is currently packaged as a zip file. We do not +have any near term plans to provide system packages. + +Once the zip is downloaded, unzip it into any directory. The `consul` binary +inside is all that is necessary to run Consul (or `consul.exe` for Windows). Any +additional files, if any, aren't required to run Consul. + +Copy the binary to anywhere on your system. If you intend to access it from the +command-line, make sure to place it somewhere on your `PATH`. + +## Compiling from Source + +To compile from source, you will need [Go](https://golang.org) installed and +configured properly (including a `GOPATH` environment variable set), as well as +a copy of [`git`](https://www.git-scm.com/) in your `PATH`. + + 1. Clone the Consul repository from GitHub into your `GOPATH`: + + ```shell + $ mkdir -p $GOPATH/src/github.com/hashicorp && cd $! + $ git clone https://github.com/hashicorp/consul.git + $ cd consul + ``` + + 1. Bootstrap the project. This will download and compile libraries and tools + needed to compile Consul: + + ```shell + $ make bootstrap + ``` + + 1. Build Consul for your current system and put the binary in `./bin/` + (relative to the git checkout). The `make dev` target is just a shortcut that + builds `consul` for only your local build environment (no cross-compiled + targets). + + ```shell + $ make dev + ``` + +## Verifying the Installation + +To verify Consul is properly installed, run `consul -v` on your system. You +should see help output. If you are executing it from the command line, make sure +it is on your PATH or you may get an error about Consul not being found. + +```shell +$ consul -v +``` diff --git a/website/source/intro/getting-started/install.html.markdown b/website/source/intro/getting-started/install.html.markdown index 95660d32e1..df01f91c0d 100644 --- a/website/source/intro/getting-started/install.html.markdown +++ b/website/source/intro/getting-started/install.html.markdown @@ -8,32 +8,26 @@ description: |- # Install Consul -Consul must first be installed on every node that will be a member of the -Consul cluster. To make installation easy, Consul is distributed as a -[binary package](/downloads.html) for all supported platforms and -architectures. This page will not cover how to compile Consul from -source. +Consul must first be installed on your machine. Consul is distributed as a +[binary package](/downloads.html) for all supported platforms and architectures. +This page will not cover how to compile Consul from source, but compiling from +source is covered in the [documentation](/docs/index.html) for those who want to +be sure they're compiling source they trust into the final binary. ## Installing Consul To install Consul, find the [appropriate package](/downloads.html) for -your system and download it. Consul is packaged as a "zip" archive. +your system and download it. Consul is packaged as a zip archive. -After downloading Consul, unzip the package. Copy the `consul` binary to -somewhere on the `PATH` so that it can be executed. On Unix systems, -`~/bin` and `/usr/local/bin` are common installation directories, -depending on if you want to restrict the install to a single user or -expose it to the entire system. On Windows systems, you can put it -wherever you would like, as long as that location is on the `%PATH%`. +After downloading Consul, unzip the package. Consul runs as a single binary +named `consul`. Any other files in the package can be safely removed and +Consul will still function. -### OS X - -If you are using [homebrew](http://brew.sh/#install) as a package manager, -you can install consul with: - -```text -$ brew install consul -``` +The final step is to make sure that the `consul` binary is available on the `PATH`. +See [this page](https://stackoverflow.com/questions/14637979/how-to-permanently-set-path-on-linux) +for instructions on setting the PATH on Linux and Mac. +[This page](https://stackoverflow.com/questions/1618280/where-can-i-set-path-to-make-exe-on-windows) +contains instructions for setting the PATH on Windows. ## Verifying the Installation @@ -48,17 +42,8 @@ usage: consul [--version] [--help] [] Available commands are: agent Runs a Consul agent event Fire a new event - exec Executes a command on Consul nodes - force-leave Forces a member of the cluster to enter the "left" state - info Provides debugging information for operators - join Tell Consul agent to join cluster - keygen Generates a new encryption key - leave Gracefully leaves the Consul cluster and shuts down - members Lists the members of a Consul cluster - monitor Stream logs from a Consul agent - reload Triggers the agent to reload configuration files - version Prints the Consul version - watch Watch for changes in Consul + +# ... ``` If you get an error that `consul` could not be found, your `PATH` diff --git a/website/source/layouts/docs.erb b/website/source/layouts/docs.erb index 0edad8ca3d..9bbeec0893 100644 --- a/website/source/layouts/docs.erb +++ b/website/source/layouts/docs.erb @@ -1,12 +1,12 @@ <% wrap_layout :inner do %> <% content_for :sidebar do %>