This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(streams | |
(changed-state {:init "ok"} | |
(email "[email protected]"))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(where (tagged "collectd") (not (:ds_type event "gauge")) | |
#(info %) | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Conclusion | |
If your development workflow is sane, then you will already understand that Docker is unnecessary. All of the features which it claims to be helpful are either useless or poorly implemented, and it's primary benefits can be easily achieved using namespaces directly. Docker would have been a cute idea 8 years ago, but it's pretty much useless today. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def default-services | |
[{:service #"^load/load/(.*)$" :rewrite "load $1"} | |
{:service #"^swap/swap_(.*)-(.*)$" :rewrite "swap $1 $2"} | |
{:service #"^memory/memory-(.*)$" :rewrite "mem $1"} | |
{:service #"^processes/ps_state-(.*)$" :rewrite "processes $1"} | |
{:service #"^aggregation-cpu-average/cpu-(.*)$" :rewrite "cpu $1"} | |
{:service #"^df-(.*)/df_complex-(.*)$" :rewrite "df $1 $2"} | |
{:service #"^interface-(.*)/if_(errors|packets|octets)/(tx|rx)$" :rewrite "nic $1 $3 $2"}]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(where (tagged "collectd") | |
(adjust [:service str/replace #"^load/load/(.*)$" "load $1"] | |
graph | |
)) | |
Metrics: | |
app1-web.load/load/shortterm | |
app1-web.load/load/midterm | |
app1-web.load/load/longterm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(alert "email" [ "[email protected]" "[email protected]" ]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(include "/etc/riemann/mycorp/process.clj" | |
(ns mycorp.queue | |
"Instrumentation and alerts for our distributed queue and consumers" | |
(:require [riemann.config :refer :all] | |
[riemann.streams :refer :all] | |
[mycorp.process :refer :all])) | |
(defn capacity [index pagerduty] ...) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Interval 10 | |
CheckThresholds true | |
LoadPlugin syslog | |
LoadPlugin cpu | |
LoadPlugin df | |
LoadPlugin interface | |
LoadPlugin load | |
LoadPlugin memory | |
LoadPlugin processes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns examplecom.email | |
"Riemann email alerting" | |
(:require [riemann.common :refer :all] | |
[riemann.core :refer :all] | |
[riemann.email :refer :all]) | |
) | |
(def header "Monitoring alert from Riemann\n\n") | |
(def footer "This is an automated Riemann notification. Please do not reply.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns examplecom.email | |
"Riemann email alerting" | |
(:require [riemann.email :refer :all] | |
[riemann.common :refer :all] | |
[clojure.string :as str] | |
[clojure.pprint :as pp]) | |
) | |
(def header "Monitoring alert from Riemann\n\n") | |
(def footer "This is an automated Riemann notification. Please do not reply.") |