This repository contains Habitat plans for the following app and libs:
-
beamium: Prometheus to Warp10 metrics forwarder
This package is released on Habitat public depot
-
c-ares: C library for asynchronous DNS requests
This package is released on Habitat public depot
-
coredns: DNS and Service Discovery
This package is released on Habitat public depot
-
haproxy: Branch 1.9.x - The Reliable, High Performance TCP/HTTP Load Balancer
This package is released on Habitat public depot
-
haproxy2: Branch 2.0.x - The Reliable, High Performance TCP/HTTP Load Balancer
This package is released on Habitat public depot
-
hashdeep: This is md5deep, a set of cross-platform tools to compute hashes
This package is released on Habitat public depot
-
openssl: Branch 1.1.x - Cryptography and SSL/TLS Toolkit
This package is released on Habitat public depot
-
pgbouncer: Lightweight connection pooler for PostgreSQL
This package is released on Habitat public depot
-
Prometheus haproxy exporter: Simple server that scrapes HAProxy stats and exports them via HTTP for Prometheus consumption
This package is released on Habitat public depot
-
Prometheus ipmi exporter: IPMI Exporter for prometheus.io, written in Go.
This package is released on Habitat public depot
-
Prometheus node exporter: Exporter for machine metrics
This package is released on Habitat public depot
-
Prometheus postfix exporter: A Prometheus exporter for Postfix.
This package is released on Habitat public depot
-
Prometheus postgres exporter: A PostgresSQL metric exporter for Prometheus
This package is released on Habitat public depot
Install Docker
and hab-cli
.
In the root directory, run:
hab studio enter
Then to build a particular package go to its directory and run build
:
cd beamium
build
Install Vagrant and run in the root directory:
vagrant up
Once this is finished, you can connect to the VM via:
vagrant ssh
The VM will have the latest hab-cli
, a hab user and group, as well as some of
the softwares helpful to test the habitat packages.
Your packages will be available at /vagrant
, in order to test one you have to
start a supervisor first, the easiest to debug is to use screen/tmux/byobu or
simply open two tabs in your terminal and connect to the vagrant VM.
In first tab/pane:
sudo hab svc run
In the second tab/pane:
hab pkg install /vagrant/prometheus-postfix_exporter/results/jonathantron-prometheus-post
fix_exporter-0.2.0-20200425093937-x86_64-linux.hart
hab svc load jonathantron/prometheus-postfix_exporter
If you want to test with a different config than the default, create a config file and apply it:
cat <<EOT >> postfix.toml
options=[
"--web.telemetry-path '/metrics'",
"--postfix.showq_path '/var/spool/postfix/public/showq'",
"--postfix.logfile_path '/var/log/mail.log'"
]
EOT
cat postfix.toml | hab config apply prometheus-postfix_exporter.default $(date +%s)
Once done, you can either stop or completely destroy the VM:
# shutdown only
vagrant down
# remove it completely
vagrant destroy
Sending package to Habitat builder
Export your Personal access token
for habitat builder and the origin
:
export HAB_AUTH_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
export HAB_ORIGIN=jonathantron
Then enter the studio again, and build your package, or if already done upload it.
hab studio enter
cd beamium
# Build the package, you can skip of already build before
build
# get the last build infos in env
source results/last_build.env
# upload package to habitat builder
hab pkg upload results/$pkg_artifact