Skip to content

Commit 2c57492

Browse files
committed
feature(2.0.0): Remove agent_bond and jboss image
1 parent d08e16c commit 2c57492

90 files changed

Lines changed: 969 additions & 5641 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

blocks/java-pkg-centos.dck

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
RUN yum install -y \
55
java-{{= fp.config.version.version }}-openjdk-{{= fp.config.base.javaPackage[major]}} \ {{? fp.param.type === "jdk" }}
66
java-{{= fp.config.version.version }}-openjdk-devel-{{= fp.config.base.javaPackage[major]}} \ {{?}}
7-
&& echo "securerandom.source=file:/dev/urandom" >> /usr/lib/jvm/{{? fp.param.type === "jdk" }}java/{{?}}jre/lib/security/java.security \
7+
&& echo "securerandom.source=file:/dev/urandom" >> /usr/lib/jvm/jre/lib/security/java.security \
88
&& yum clean all
99

1010
ENV JAVA_HOME /etc/alternatives/jre
File renamed without changes.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/sh
2+
# Scripted for getting Prometheus options
3+
# meant to be evaluated (not to be sourced)
4+
5+
# Exit if switched off
6+
if [ -n "${AB_PROMETHEUS_OFF:-}" ] && [ "${AB_PROMETHEUS_OFF}" != "false" ]; then
7+
exit 0
8+
fi
9+
10+
# Global switch, turning of all agents
11+
if [ -n "${AB_OFF:-}" ] && [ "${AB_OFF}" != "false" ]; then
12+
exit 0
13+
fi
14+
15+
port=${AB_PROMETHEUS_PORT:-9779}
16+
config=${AB_PROMETHEUS_CONFIG:-/opt/prometheus/prometheus-config.yml}
17+
if [ -n "${AB_PROMETHEUS_HOST:-}" ]; then
18+
hostPort="${AB_PROMETHEUS_HOST}:$port"
19+
else
20+
hostPort="$port"
21+
fi
22+
23+
echo "-javaagent:/opt/prometheus/jmx_prometheus_javaagent.jar=${hostPort}:$config"
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{{
2-
var destPath = fp.blockOpts.dest || "/opt/prometheus/prometheus-options";
2+
var destPath = fp.blockOpts.dest || "/opt/prometheus/prometheus-opts";
33
var globalVersions = fp.version || {};
4-
var jmxExporterVersion = fp.blockOpts.version || globalVersions.jmxexporter;
4+
var jmxExporterVersion = fp.blockOpts.version || globalVersions.jmx_exporter;
55
var jmxExporterArtifact = fp.blockOpts.jmxExporterArtifact || "jmx_prometheus_javaagent";
66
var mavenRepo = fp.blockOpts.mavenRepo || "http://central.maven.org/maven2";
77
var userGroupMode = fp.blockOpts.userGroupMode;

blocks/jmx_exporter/readme.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#### jmx_exporter Configuration
2+
3+
* **AB_OFF** and **AB_PROMETHEUS_OFF**: If set to any value except 'false', disable Prometheus export
4+
* **AB_PROMETHEUS_PORT** : Port to expose Prometheus (default: 9779)
5+
* **AB_PROMETHEUS_HOST** : Host address to listen on for exporting Prometheus metrics. Otherwise the exporter listens on any IP
6+
* **AB_PROMETHEUS_CONFIG** : Path to the Prometheus configuration file (default: `/opt/prometheus/prometheus-config.yml`

blocks/jmxexporter/fp-files/prometheus-opts

Lines changed: 0 additions & 57 deletions
This file was deleted.

blocks/jolokia/fp-files/jolokia-opts

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
#!/bin/sh
22

3+
4+
# Exit if switched off
5+
if [ -n "${AB_JOLOKIA_OFF:-}" ] && [ "${AB_JOLOKIA_OFF}" != "false" ]; then
6+
exit 0
7+
fi
8+
9+
# Global switch, turning of all agents
10+
if [ -n "${AB_OFF:-}" ] && [ "${AB_OFF}" != "false" ]; then
11+
exit 0
12+
fi
13+
314
# Check whether a given config is contained in AB_JOLOKIA_OPTS
415
is_in_jolokia_opts() {
516
local prop=$1
@@ -85,10 +96,8 @@ EOF
8596

8697
}
8798

88-
if [ -z "${AB_JOLOKIA_OFF:-}" ]; then
89-
if [ -z "${AB_JOLOKIA_CONFIG:-}" ]; then
90-
AB_JOLOKIA_CONFIG="/opt/jolokia/etc/jolokia.properties"
91-
write_jolokia_properties "$AB_JOLOKIA_CONFIG"
92-
fi
93-
echo "-javaagent:/opt/jolokia/jolokia.jar=config=${AB_JOLOKIA_CONFIG}"
99+
if [ -z "${AB_JOLOKIA_CONFIG:-}" ]; then
100+
AB_JOLOKIA_CONFIG="/opt/jolokia/etc/jolokia.properties"
101+
write_jolokia_properties "$AB_JOLOKIA_CONFIG"
94102
fi
103+
echo "-javaagent:/opt/jolokia/jolokia.jar=config=${AB_JOLOKIA_CONFIG}"

blocks/jolokia/install.dck

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{{
2-
var destPath = fp.blockOpts.dest || "/bin/jolokia-options";
2+
var destPath = fp.blockOpts.dest || "/opt/jolokia/jolokia-options";
33
var globalVersions = fp.version || {};
44
var jolokiaVersion = fp.blockOpts.version || globalVersions.jolokia || "1.5.0";
55
var jolokiaArtifact = jolokiaVersion.match(/^2.*$/) ? "jolokia-agent-jvm" : "jolokia-jvm";

blocks/jolokia/readme.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
#### Jolokia configuration
1+
#### Jolokia Configuration
22

33
* **AB_JOLOKIA_OFF** : If set disables activation of Jolokia (i.e. echos an empty value). By default, Jolokia is enabled.
4-
* **AB_JOLOKIA_CONFIG** : If set uses this file (including path) as Jolokia JVM agent properties (as described
5-
in Jolokia's [reference manual](http://www.jolokia.org/reference/html/agents.html#agents-jvm)). If not set,
4+
* **AB_JOLOKIA_CONFIG** : If set uses this file (including path) as Jolokia JVM agent properties (as described
5+
in Jolokia's [reference manual](http://www.jolokia.org/reference/html/agents.html#agents-jvm)). If not set,
66
the `/opt/jolokia/etc/jolokia.properties` will be created using the settings as defined in this document, otherwise
77
the reset of the settings in this document are ignored.
88
* **AB_JOLOKIA_HOST** : Host address to bind to (Default: `0.0.0.0`)
@@ -14,13 +14,12 @@
1414
if no `serverCert` configuration is given in `AB_JOLOKIA_OPTS`
1515
* **AB_JOLOKIA_ID** : Agent ID to use (`$HOSTNAME` by default, which is the container id)
1616
* **AB_JOLOKIA_DISCOVERY_ENABLED** : Enable Jolokia discovery. Defaults to false.
17-
* **AB_JOLOKIA_OPTS** : Additional options to be appended to the agent configuration. They should be given in the format
17+
* **AB_JOLOKIA_OPTS** : Additional options to be appended to the agent configuration. They should be given in the format
1818
"key=value,key=value,..."
1919

2020
Some options for integration in various environments:
2121

22-
* **AB_JOLOKIA_AUTH_OPENSHIFT** : Switch on client authentication for OpenShift TSL communication. The value of this
22+
* **AB_JOLOKIA_AUTH_OPENSHIFT** : Switch on client authentication for OpenShift TSL communication. The value of this
2323
parameter can be a relative distinguished name which must be contained in a presented client certificate. Enabling this
24-
parameter will automatically switch Jolokia into https communication mode. The default CA cert is set to
25-
`/var/run/secrets/kubernetes.io/serviceaccount/ca.crt`
26-
24+
parameter will automatically switch Jolokia into https communication mode. The default CA cert is set to
25+
`/var/run/secrets/kubernetes.io/serviceaccount/ca.crt`

fish-pepper.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Versions of support libs
44
version:
55
jolokia: "1.6.0"
6-
jmxExporter: "0.11.0"
6+
jmx_exporter: "0.11.0"
77

88
# Who to blame
99
maintainer: "rhuss@redhat.com"

0 commit comments

Comments
 (0)