Skip to content

Commit

Permalink
Merge pull request #43 from bpineau/example_configfile
Browse files Browse the repository at this point in the history
Add an example configuration file and better goreleaser config
  • Loading branch information
bpineau authored Apr 23, 2018
2 parents 729fc03 + bdd7ddf commit f7b5700
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 4 deletions.
21 changes: 19 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,17 @@ builds:
- linux
goarch:
- amd64
- arm
- arm64
- "386"

release:
# don't autopublish
draft: true

sign:
artifacts: checksum

archive:
format: binary

Expand All @@ -36,11 +42,22 @@ nfpm:
description: Discover and continuously backup Kubernetes objets as yaml files in git
maintainer: Benjamin Pineau <[email protected]>
license: MIT
bindir: /usr/bin
vendor: Benjamin Pineau
formats:
- deb
- rpm
dependencies:
- git
replacements:
amd64: x86_64
config_files:
"./assets/katafygio.yaml": "/etc/katafygio/katafygio.yaml"
overrides:
rpm:
replacements:
amd64: x86_64
386: i686
name_template: "{{ .ProjectName }}-{{ .Version }}-{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
deb:
replacements:
386: i386
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,9 @@ Flags:

## Config file and env variables

All settings can be passed by command line options, or environment variable, or in a yaml
configuration file (thanks to Viper and Cobra libs). The environment are the same as cli options,
All settings can be passed by command line options, or environment variable, or in
[a yaml configuration file](https://github.com/bpineau/katafygio/blob/master/assets/katafygio.yaml)
(thanks to Viper and Cobra libs). The environment are the same as cli options,
in uppercase, prefixed by "KF", and with underscore instead of dashs. ie.:

```
Expand Down
44 changes: 44 additions & 0 deletions assets/katafygio.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
## Katafygio configuration file

# To provide alternate api-server URL or config to reach the cluster:
#api-server: http://127.0.0.1:8080
#kube-config: /etc/kubernetes/config

log:
level: "info"
output: "stderr"
#server: "localhost:514" # mandatory if log-output: "syslog"

# Where to save the yaml dumps
local-dir: /var/cache/katafygio

# Remote url is optional. If provided, Katafygio will push there.
#git-url: https://user:[email protected]/myorg/myrepos.git

# Port to listen for http health check probes. 0 to disable.
healthcheck-port: 0

# How often should Katafygio full resync. Only needed to catch possibly
# missed events: events are handled in real-time. 0 to disable.
resync-interval: 900

# To only include objects matching a kubernetes selector:
#filter: "vendor=foo,app=bar"

# Example exclusions by object kind. E.g.: keep secrets confidential,
# don't dump pods or replicaset they are all managed by deployments
# or daemonsets (which are already dumped), endpoints (managed by services,
# already dumped), and noisy stuff (events, nodes...).
#exclude-kind:
# - secret
# - pod
# - replicaset
# - node
# - event
# - endpoints

# Example exclusion for specific objects:
#exclude-object:
# - configmap:kube-system/datadog-leader-elector
# - deployment:default/testdeploy

0 comments on commit f7b5700

Please sign in to comment.