Updating docs to reference new binary and package (#1557)

This commit is contained in:
Mike Arpaia 2017-10-05 19:33:41 -06:00 коммит произвёл GitHub
Родитель 80b082ea26
Коммит 5cbef6270b
9 изменённых файлов: 59 добавлений и 58 удалений

Просмотреть файл

@ -1,7 +1,7 @@
Configuring The Kolide Binary
Configuring The Fleet Binary
=============================
For information on how to run the `kolide` binary, detailed usage information can be found by running `kolide --help`. This document is a more detailed version of the information presented in the help output text. If you prefer to use a CLI instead of a web browser, we hope that you like the binary interface to the Fleet application!
For information on how to run the `fleet` binary, detailed usage information can be found by running `fleet --help`. This document is a more detailed version of the information presented in the help output text. If you prefer to use a CLI instead of a web browser, we hope that you like the binary interface to the Fleet application!
## High-level configuration overview
@ -26,12 +26,12 @@ Since Fleet is an osquery TLS server, you are also able to define configurations
## Commands
The `kolide` binary contains several "commands". Similarly to how `git` has many commands (`git status`, `git commit`, etc), the `kolide` binary accepts the following commands:
The `fleet` binary contains several "commands". Similarly to how `git` has many commands (`git status`, `git commit`, etc), the `fleet` binary accepts the following commands:
- `kolide prepare db`
- `kolide serve`
- `kolide version`
- `kolide config_dump`
- `fleet prepare db`
- `fleet serve`
- `fleet version`
- `fleet config_dump`
## Options
@ -48,7 +48,7 @@ For example, all of the following ways of launching Fleet are equivalent:
#### Using only CLI flags
```
$ /usr/bin/kolide serve \
$ /usr/bin/fleet serve \
--mysql_address=127.0.0.1:3306 \
--mysql_database=kolide \
--mysql_username=root \
@ -70,7 +70,7 @@ $ KOLIDE_MYSQL_ADDRESS=127.0.0.1:3306 \
KOLIDE_SERVER_CERT=/tmp/server.cert \
KOLIDE_SERVER_KEY=/tmp/server.key \
KOLIDE_LOGGING_JSON=true \
/usr/bin/kolide serve
/usr/bin/fleet serve
```
#### Using a config file
@ -90,7 +90,7 @@ server:
logging:
json: true
' > /tmp/kolide.yml
$ kolide serve --config /tmp/kolide.yml
$ fleet serve --config /tmp/kolide.yml
```
### What are the options?
@ -228,7 +228,7 @@ The server name or IP address used by the client certificate.
##### `redis_address`
The address of the Redis server which Kolide should connect to. Include the hostname and port.
The address of the Redis server which Fleet should connect to. Include the hostname and port.
- Default value: `localhost:3306`
- Default value: `localhost:6379`

Просмотреть файл

@ -22,7 +22,7 @@ To install Fleet, run the following:
```
$ sudo rpm -ivh https://dl.kolide.co/yum/kolide-yum-repo-1.0.0-1.noarch.rpm
$ sudo yum install kolide
$ sudo yum install fleet
```
## Installing and configuring dependencies
@ -81,10 +81,10 @@ $ sudo service redis start
## Running the Fleet server
Now that we have installed Fleet, MySQL, and Redis, we are ready to launch Fleet! First, we must "prepare" the database. We do this via `kolide prepare db`:
Now that we have installed Fleet, MySQL, and Redis, we are ready to launch Fleet! First, we must "prepare" the database. We do this via `fleet prepare db`:
```
$ /usr/bin/kolide prepare db \
$ /usr/bin/fleet prepare db \
--mysql_address=127.0.0.1:3306 \
--mysql_database=kolide \
--mysql_username=root \
@ -118,10 +118,10 @@ You should now have three new files in `/tmp`:
- `/tmp/server.key`
- `/tmp/server.csr`
Now we are ready to run the server! We do this via `kolide serve`:
Now we are ready to run the server! We do this via `fleet serve`:
```
$ /usr/bin/kolide serve \
$ /usr/bin/fleet serve \
--mysql_address=127.0.0.1:3306 \
--mysql_database=kolide \
--mysql_username=root \

Просмотреть файл

@ -24,7 +24,7 @@ To install Fleet, run the following:
$ wget -qO - https://dl.kolide.co/archive.key | sudo apt-key add -
$ sudo add-apt-repository "deb https://dl.kolide.co/apt jessie main"
$ sudo apt-get update
$ sudo apt-get install kolide
$ sudo apt-get install fleet
```
## Installing and configuring dependencies
@ -70,10 +70,10 @@ Note that this isn't a very robust way to run a Redis server. Digital Ocean has
## Running the Fleet server
Now that we have installed Fleet, MySQL, and Redis, we are ready to launch Fleet! First, we must "prepare" the database. We do this via `kolide prepare db`:
Now that we have installed Fleet, MySQL, and Redis, we are ready to launch Fleet! First, we must "prepare" the database. We do this via `fleet prepare db`:
```
$ /usr/bin/kolide prepare db \
$ /usr/bin/fleet prepare db \
--mysql_address=127.0.0.1:3306 \
--mysql_database=kolide \
--mysql_username=root \
@ -107,10 +107,10 @@ You should now have three new files in `/tmp`:
- `/tmp/server.key`
- `/tmp/server.csr`
Now we are ready to run the server! We do this via `kolide serve`:
Now we are ready to run the server! We do this via `fleet serve`:
```
$ /usr/bin/kolide serve \
$ /usr/bin/fleet serve \
--mysql_address=127.0.0.1:3306 \
--mysql_database=kolide \
--mysql_username=root \

Просмотреть файл

@ -7,7 +7,7 @@ The Fleet application is distributed as a single static binary. This binary serv
- The Fleet application API endpoints
- The osquery TLS server API endpoints
All of these are served via a built-in HTTP server, so there is no need for complex web server configurations. Once you've installed the `kolide` binary and it's infrastructure dependencies as illustrated below, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation for information on how to use and configure the Fleet application.
All of these are served via a built-in HTTP server, so there is no need for complex web server configurations. Once you've installed the `fleet` binary and it's infrastructure dependencies as illustrated below, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation for information on how to use and configure the Fleet application.
## Fleet Quickstart
@ -22,7 +22,7 @@ Because everyone's infrastructure is different, there are a multiple options ava
Pull the latest Fleet docker image:
```
docker pull kolide/kolide
docker pull kolide/fleet
```
For more information on using Fleet, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation.
@ -40,8 +40,8 @@ sudo apt-get update
Install Fleet:
```
sudo apt-get install kolide
/usr/bin/kolide --help
sudo apt-get install fleet
/usr/bin/fleet --help
```
For more information on using Fleet, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation.
@ -57,8 +57,8 @@ sudo rpm -ivh https://dl.kolide.co/yum/kolide-yum-repo-1.0.0-1.noarch.rpm
Install Fleet:
```
sudo yum install kolide
kolide --help
sudo yum install fleet
fleet --help
```
For more information on using Fleet, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation.
@ -68,31 +68,31 @@ For more information on using Fleet, refer to the [Configuring The Fleet Binary]
Download the latest raw Fleet binaries:
```
curl -O https://dl.kolide.co/bin/kolide_latest.zip
curl -O https://dl.kolide.co/bin/fleet_latest.zip
```
Unzip the binaries for your platform:
```
# For a Darwin compatible binary
unzip kolide_latest.zip 'darwin/*' -d kolide
./kolide/darwin/kolide_darwin_amd64 --help
unzip fleet_latest.zip 'darwin/*' -d fleet
./fleet/darwin/fleet_darwin_amd64 --help
# For a Linux compatible binary
unzip kolide_latest.zip 'linux/*' -d kolide
./kolide/linux/kolide_linux_amd64 --help
unzip fleet_latest.zip 'linux/*' -d fleet
./fleet/linux/fleet_linux_amd64 --help
```
For more information on using Fleet, refer to the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) documentation.
## Infrastructure Dependencies
Fleet currently has two infrastructure dependencies in addition to the `kolide` web server itself. Those dependencies are MySQL and Redis.
Fleet currently has two infrastructure dependencies in addition to the `fleet` web server itself. Those dependencies are MySQL and Redis.
#### MySQL
Fleet uses MySQL extensively as it's main database. Many cloud providers (such as [AWS](https://aws.amazon.com/rds/mysql/) and [GCP](https://cloud.google.com/sql/)) host reliable MySQL services which you may consider for this purpose. A well supported MySQL [Docker container](https://hub.docker.com/_/mysql/) also exists if you would rather run MySQL in a container. For more information on how to configure the `kolide` binary to use the correct MySQL instance, see the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) document.
Fleet uses MySQL extensively as it's main database. Many cloud providers (such as [AWS](https://aws.amazon.com/rds/mysql/) and [GCP](https://cloud.google.com/sql/)) host reliable MySQL services which you may consider for this purpose. A well supported MySQL [Docker container](https://hub.docker.com/_/mysql/) also exists if you would rather run MySQL in a container. For more information on how to configure the `fleet` binary to use the correct MySQL instance, see the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) document.
#### Redis
Fleet uses Redis to ingest and queue the results of distributed queries, cache data, etc. Many cloud providers (such as [AWS](https://aws.amazon.com/elasticache/) and [GCP](https://console.cloud.google.com/launcher/details/click-to-deploy-images/redis)) host reliable Redis services which you may consider for this purpose. A well supported Redis [Docker container](https://hub.docker.com/_/redis/) also exists if you would rather run Redis in a container. For more information on how to configure the `kolide` binary to use the correct Redis instance, see the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) document.
Fleet uses Redis to ingest and queue the results of distributed queries, cache data, etc. Many cloud providers (such as [AWS](https://aws.amazon.com/elasticache/) and [GCP](https://console.cloud.google.com/launcher/details/click-to-deploy-images/redis)) host reliable Redis services which you may consider for this purpose. A well supported Redis [Docker container](https://hub.docker.com/_/redis/) also exists if you would rather run Redis in a container. For more information on how to configure the `fleet` binary to use the correct Redis instance, see the [Configuring The Fleet Binary](./configuring-the-fleet-binary.md) document.

Просмотреть файл

@ -29,7 +29,7 @@ Step 2 is performed automatically, so no further action is necessary.
Pull the latest Fleet docker image:
```
docker pull kolide/kolide
docker pull kolide/fleet
```
#### Debian Packages (Ubuntu, Debian)
@ -37,7 +37,7 @@ docker pull kolide/kolide
Update Fleet through the Apt repository (the repository should have been added during initial install):
```
sudo apt-get update && sudo apt-get install kolide
sudo apt-get update && sudo apt-get install fleet
```
#### Yum Packages (CentOS, RHEL, Amazon Linux)
@ -45,7 +45,7 @@ sudo apt-get update && sudo apt-get install kolide
Update Fleet through the Yum respository (the repository should have been added during initial install):
```
sudo yum update kolide
sudo yum update fleet
```
#### Raw binaries
@ -53,19 +53,19 @@ sudo yum update kolide
Download the latest raw Fleet binaries:
```
curl -O https://dl.kolide.co/bin/kolide_latest.zip
curl -O https://dl.kolide.co/bin/fleet_latest.zip
```
Unzip the binaries for your platform:
```
# For a Darwin compatible binary
unzip kolide_latest.zip 'darwin/*' -d kolide
./kolide/darwin/kolide_darwin_amd64 --help
unzip fleet_latest.zip 'darwin/*' -d fleet
./fleet/darwin/fleet_darwin_amd64 --help
# For a Linux compatible binary
unzip kolide_latest.zip 'linux/*' -d kolide
./kolide/linux/kolide_linux_amd64 --help
unzip fleet_latest.zip 'linux/*' -d fleet
./fleet/linux/fleet_linux_amd64 --help
```
Replace the existing Fleet binary with the newly unzipped binary.
@ -75,7 +75,7 @@ Replace the existing Fleet binary with the newly unzipped binary.
Before running the updated server, perform necessary database migrations:
```
kolide prepare db
fleet prepare db
```
Note, if you would like to run this in a script, you can use the `--no-prompt` option to disable prompting before the migrations.
@ -83,5 +83,5 @@ Note, if you would like to run this in a script, you can use the `--no-prompt` o
The updated Fleet server should now be ready to run:
```
kolide serve
fleet serve
```

Просмотреть файл

@ -14,7 +14,8 @@ GPG keys in your keyring.
1. Download the Google Storage bucket locally.
```
gsutil cp -r gs://dl.kolide.co/ /Users/$user/kolide_packages/
mkdir -p ~/kolide_packages
gsutil cp -r gs://dl.kolide.co/ ~/kolide_packages/
```
2. Import keys to GPG keyring. Run this command by mounting the `~/.gnupg` folder into the `kolide/fpm` docker container. The gnupg version on your mac is probably different and the keyring format is not compatible with the one in the container. The permissions on .gnupg should be 700 and the files in the .gnupg directory need to be 600.
@ -49,10 +50,10 @@ You will be prompted for the GPG password several times by the rpm/deb packaging
Example:
```
cp build/kolide-1.0.4-1.x86_64.rpm ~/kolide_packages/yum/
cp build/kolide_1.0.4_amd64.deb ~/kolide_packages/deb
cp build/kolide_1.0.4.zip ~/kolide_packages/bin
cp build/kolide_latest.zip ~/kolide_packages/bin/kolide_latest.zip
cp build/fleet-1.0.4-1.x86_64.rpm ~/kolide_packages/yum/
cp build/fleet_1.0.4_amd64.deb ~/kolide_packages/deb/
cp build/fleet_1.0.4.zip ~/kolide_packages/bin/
cp build/fleet_latest.zip ~/kolide_packages/bin/
```
5. Run the `update-package-repos` script. The script will update/sign the metadata for the local yum/apt repos. You will be prompted for the GPG key password again during this step so have it ready.

Просмотреть файл

@ -9,23 +9,23 @@ build_binaries() {
GOOS=darwin CGO_ENABLED=0 make build
mkdir -p build/darwin
mv build/kolide build/darwin/kolide_darwin_amd64
mv build/fleet build/darwin/fleet_darwin_amd64
GOOS=linux CGO_ENABLED=0 make build
mkdir -p build/linux
mv build/kolide build/linux/kolide_linux_amd64
mv build/fleet build/linux/fleet_linux_amd64
}
zip_binaries() {
cd build && \
zip -r "kolide_${VERSION}.zip" darwin/ linux/ && \
cp "kolide_${VERSION}.zip" kolide_latest.zip && \
zip -r "fleet_${VERSION}.zip" darwin/ linux/ && \
cp "fleet_${VERSION}.zip" fleet_latest.zip && \
cd ..
}
build_linux_packages() {
mkdir -p build/pkgroot/usr/bin
cp build/linux/kolide_linux_amd64 build/pkgroot/usr/bin/kolide
cp build/linux/fleet_linux_amd64 build/pkgroot/usr/bin/fleet
docker run --rm -it \
-v ${PWD}/build/pkgroot:/pkgroot \
-v "${GPG_PATH}:/root/.gnupg" \

Просмотреть файл

@ -109,7 +109,7 @@ func getMetadata(repoPath, current string) (*metadata, error) {
// add current release docker hub link
p := pkg{
Kind: "docker",
Name: "kolide/kolide:" + current,
Name: "kolide/fleet:" + current,
}
m.Current = append(m.Current, p)
return &m, nil

Просмотреть файл

@ -30,8 +30,8 @@ update_apt_repo() {
-v "${LOCAL_REPO_PATH}/aptly.conf:/root/.aptly.conf" aptly
# replace "debian" repo with updated snapshot
rm -rf "${LOCAL_REPO_PATH}/apt"
mv "${LOCAL_REPO_PATH}/aptly/public" "${LOCAL_REPO_PATH}/apt"
rm -rf "${LOCAL_REPO_PATH}/apt"
mv "${LOCAL_REPO_PATH}/aptly/public" "${LOCAL_REPO_PATH}/apt"
}