https://github.com/danstough/consul-scenarios
https://github.com/danstough/consul-scenarios
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/danstough/consul-scenarios
- Owner: DanStough
- Created: 2022-08-24T19:53:51.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-07-12T18:58:08.000Z (11 months ago)
- Last Synced: 2025-02-08T20:24:02.029Z (4 months ago)
- Language: HCL
- Size: 121 KB
- Stars: 4
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Consul Testing Scenarios
## Contributors
* @erichaberkorn
* @DanStough
* @jessingrass
* @hashi-derek
* @andrewstuckiThese scenarios are divided into 3 categories of target environment:
1. **Local** - to be run on a single workstation
2. **Kubernetes** - to be run on a Kubernetes cluster
3. **VMs** - to be run in separate VMs## Local
### Prequisites* On Mac, have Consul and Envoy installed via Homebrew
* On Linux, install Consul and Envoy via the package manager. Envoy won't work for `ARM64`See `install-server.sh`.
### Basic
Run dev agent (both server and client)
```bash
consul agent -dev
```Run in the background
```bash
consul agent -config-dir=./consul-scenarios/consul.d -dev > ./consul-scenarios/logs/test-one.log &# Show the jobs
jobs
# [1]+ Running consul agent -config-dir=./consul-scenarios/consul.d -dev > ./consul-scenarios/logs/test-one.log &# Cancel the jobs
fg %1
#
```Run dev agent with configuration file
```bash
consul agent -config-dir=./consul-scenarios/dev-peering.hcl -dev
```
To add a service, just use both one of the `dev`, `server` or `client` files in conjunction with the HCL service definition.