commit
0351ffcbd4
@ -35,3 +35,10 @@ MINION_IP_RANGES=($(eval echo "10.244.{1..${NUM_MINIONS}}.0/24"))
|
|||||||
MINION_SCOPES=""
|
MINION_SCOPES=""
|
||||||
POLL_SLEEP_INTERVAL=3
|
POLL_SLEEP_INTERVAL=3
|
||||||
PORTAL_NET="10.0.0.0/16"
|
PORTAL_NET="10.0.0.0/16"
|
||||||
|
|
||||||
|
# Optional: Install node monitoring.
|
||||||
|
ENABLE_NODE_MONITORING=true
|
||||||
|
|
||||||
|
# Optional: Install node logging
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch # options: elasticsearch, gcp
|
||||||
|
@ -22,8 +22,9 @@ mkdir -p /srv/salt-overlay/pillar
|
|||||||
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
||||||
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
||||||
portal_net: $PORTAL_NET
|
portal_net: $PORTAL_NET
|
||||||
use-fluentd-es: $FLUENTD_ELASTICSEARCH
|
enable_node_monitoring: $ENABLE_NODE_MONITORING
|
||||||
use-fluentd-gcp: $FLUENTD_GCP
|
enable_node_logging: $ENABLE_NODE_LOGGING
|
||||||
|
logging_destination: $LOGGING_DESTINATION
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
mkdir -p /srv/salt-overlay/salt/nginx
|
mkdir -p /srv/salt-overlay/salt/nginx
|
||||||
|
@ -106,14 +106,14 @@ function ensure-temp-dir {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function setup-monitoring {
|
function setup-monitoring {
|
||||||
if [ ${MONITORING-} ]; then
|
if [[ "${ENABLE_CLUSTER_MONITORING}" == "true" ]]; then
|
||||||
# TODO: Implement this.
|
# TODO: Implement this.
|
||||||
echo "Monitoring not currently supported on AWS"
|
echo "Monitoring not currently supported on AWS"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
function teardown-monitoring {
|
function teardown-monitoring {
|
||||||
if [ ${MONITORING-} ]; then
|
if [[ "${ENABLE_CLUSTER_MONITORING}" == "true" ]]; then
|
||||||
# TODO: Implement this.
|
# TODO: Implement this.
|
||||||
echo "Monitoring not currently supported on AWS"
|
echo "Monitoring not currently supported on AWS"
|
||||||
fi
|
fi
|
||||||
@ -255,8 +255,9 @@ function kube-up {
|
|||||||
echo "readonly AWS_ZONE='${ZONE}'"
|
echo "readonly AWS_ZONE='${ZONE}'"
|
||||||
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
||||||
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
||||||
echo "readonly FLUENTD_ELASTICSEARCH='${FLUENTD_ELASTICSEARCH:-false}'"
|
echo "readonly ENABLE_NODE_MONITORING='${ENABLE_NODE_MONITORING:-false}'"
|
||||||
echo "readonly FLUENTD_GCP='false'"
|
echo "readonly ENABLE_NODE_LOGGING='${ENABLE_NODE_LOGGING:-false}'"
|
||||||
|
echo "readonly LOGGING_DESTINATION='${LOGGING_DESTINATION:-}'"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/create-dynamic-salt-files.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/create-dynamic-salt-files.sh"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/download-release.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/download-release.sh"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/salt-master.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/aws/templates/salt-master.sh"
|
||||||
|
@ -35,14 +35,16 @@ MINION_SCOPES=("storage-ro" "compute-rw")
|
|||||||
# Increase the sleep interval value if concerned about API rate limits. 3, in seconds, is the default.
|
# Increase the sleep interval value if concerned about API rate limits. 3, in seconds, is the default.
|
||||||
POLL_SLEEP_INTERVAL=3
|
POLL_SLEEP_INTERVAL=3
|
||||||
PORTAL_NET="10.0.0.0/16"
|
PORTAL_NET="10.0.0.0/16"
|
||||||
# When set to true, heapster will be setup as part of the cluster bring up.
|
|
||||||
MONITORING=true
|
# Optional: Install node monitoring.
|
||||||
# Turn on Elasticsearch logging unless Google Cloud Logging has been selected or
|
ENABLE_NODE_MONITORING=true
|
||||||
# if Elasticsearch logging has been specifically turned off.
|
|
||||||
if [[ "${FLUENTD_GCP-}" != "true" ]]; then
|
# Optional: When set to true, heapster will be setup as part of the cluster bring up.
|
||||||
if [[ "${FLUENTD_ELASTICSEARCH-}" != "false" ]]; then
|
ENABLE_CLUSTER_MONITORING=true
|
||||||
FLUENTD_ELASTICSEARCH="true"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
# When set to true, Docker Cache is enabled by default as part of the cluster bring up.
|
# When set to true, Docker Cache is enabled by default as part of the cluster bring up.
|
||||||
ENABLE_DOCKER_REGISTRY_CACHE=true
|
ENABLE_DOCKER_REGISTRY_CACHE=true
|
||||||
|
|
||||||
|
# Optional: Enable node logging.
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch # options: elasticsearch, gcp
|
||||||
|
@ -35,7 +35,13 @@ MINION_SCOPES=("storage-ro" "compute-rw")
|
|||||||
# Increase the sleep interval value if concerned about API rate limits. 3, in seconds, is the default.
|
# Increase the sleep interval value if concerned about API rate limits. 3, in seconds, is the default.
|
||||||
POLL_SLEEP_INTERVAL=3
|
POLL_SLEEP_INTERVAL=3
|
||||||
PORTAL_NET="10.0.0.0/16"
|
PORTAL_NET="10.0.0.0/16"
|
||||||
MONITORING=false
|
|
||||||
|
|
||||||
# When set to true, Docker Cache is enabled by default as part of the cluster bring up.
|
# When set to true, Docker Cache is enabled by default as part of the cluster bring up.
|
||||||
ENABLE_DOCKER_REGISTRY_CACHE=true
|
ENABLE_DOCKER_REGISTRY_CACHE=true
|
||||||
|
|
||||||
|
ENABLE_NODE_MONITORING=true
|
||||||
|
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch # options: elasticsearch, gcp
|
||||||
|
|
||||||
|
ENABLE_CLUSTER_MONITORING=false
|
||||||
|
@ -22,8 +22,9 @@ mkdir -p /srv/salt-overlay/pillar
|
|||||||
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
||||||
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
||||||
portal_net: $PORTAL_NET
|
portal_net: $PORTAL_NET
|
||||||
use-fluentd-es: $FLUENTD_ELASTICSEARCH
|
enable_node_monitoring: $ENABLE_NODE_MONITORING
|
||||||
use-fluentd-gcp: $FLUENTD_GCP
|
enable_node_logging: $ENABLE_NODE_LOGGING
|
||||||
|
logging_destination: $LOGGING_DESTINATION
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
mkdir -p /srv/salt-overlay/salt/nginx
|
mkdir -p /srv/salt-overlay/salt/nginx
|
||||||
|
@ -283,8 +283,9 @@ function kube-up {
|
|||||||
echo "readonly SALT_TAR_URL='${SALT_TAR_URL}'"
|
echo "readonly SALT_TAR_URL='${SALT_TAR_URL}'"
|
||||||
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
||||||
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
||||||
echo "readonly FLUENTD_ELASTICSEARCH='${FLUENTD_ELASTICSEARCH:-false}'"
|
echo "readonly ENABLE_NODE_MONITORING='${ENABLE_NODE_MONITORING:-false}'"
|
||||||
echo "readonly FLUENTD_GCP='${FLUENTD_GCP:-false}'"
|
echo "readonly ENABLE_NODE_LOGGING='${ENABLE_NODE_LOGGING:-false}'"
|
||||||
|
echo "readonly LOGGING_DESTINATION='${LOGGING_DESTINATION:-}'"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/common.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/common.sh"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/create-dynamic-salt-files.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/create-dynamic-salt-files.sh"
|
||||||
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/download-release.sh"
|
grep -v "^#" "${KUBE_ROOT}/cluster/gce/templates/download-release.sh"
|
||||||
@ -292,16 +293,12 @@ function kube-up {
|
|||||||
) > "${KUBE_TEMP}/master-start.sh"
|
) > "${KUBE_TEMP}/master-start.sh"
|
||||||
|
|
||||||
# Report logging choice (if any).
|
# Report logging choice (if any).
|
||||||
if [[ "${FLUENTD_ELASTICSEARCH-}" == "true" ]]; then
|
if [[ "${ENABLE_NODE_LOGGING-}" == "true" ]]; then
|
||||||
echo "+++ Logging using Fluentd to Elasticsearch"
|
echo "+++ Logging using Fluentd to ${LOGGING_DESTINATION:-unknown}"
|
||||||
fi
|
# For logging to GCP we need to enable some minion scopes.
|
||||||
if [[ "${FLUENTD_GCP-}" == "true" ]]; then
|
if [[ "${LOGGING_DESTINATION-}" == "gcp" ]]; then
|
||||||
echo "+++ Logging using Fluentd to Google Cloud Logging"
|
MINION_SCOPES="${MINION_SCOPES}, https://www.googleapis.com/auth/logging.write"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# For logging to GCP we need to enable some minion scopes.
|
|
||||||
if [[ "${FLUENTD_GCP-}" == "true" ]]; then
|
|
||||||
MINION_SCOPES="${MINION_SCOPES}, https://www.googleapis.com/auth/logging.write"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
gcloud compute instances create "${MASTER_NAME}" \
|
gcloud compute instances create "${MASTER_NAME}" \
|
||||||
@ -566,7 +563,7 @@ function restart-kube-proxy {
|
|||||||
|
|
||||||
# Setup monitoring using heapster and InfluxDB
|
# Setup monitoring using heapster and InfluxDB
|
||||||
function setup-monitoring {
|
function setup-monitoring {
|
||||||
if [[ "${MONITORING}" == "true" ]]; then
|
if [[ "${ENABLE_CLUSTER_MONITORING}" == "true" ]]; then
|
||||||
echo "Setting up cluster monitoring using Heapster."
|
echo "Setting up cluster monitoring using Heapster."
|
||||||
|
|
||||||
if ! gcloud compute firewall-rules describe monitoring-heapster &>/dev/null; then
|
if ! gcloud compute firewall-rules describe monitoring-heapster &>/dev/null; then
|
||||||
@ -584,9 +581,9 @@ function setup-monitoring {
|
|||||||
|
|
||||||
cp "${KUBE_ROOT}/examples/monitoring/influx-grafana-pod.json" "${KUBE_TEMP}/influx-grafana-pod.0.json"
|
cp "${KUBE_ROOT}/examples/monitoring/influx-grafana-pod.json" "${KUBE_TEMP}/influx-grafana-pod.0.json"
|
||||||
sed "s/HTTP_USER, \"value\": \"[^\"]*\"/HTTP_USER, \"value\": \"$KUBE_USER\"/g" \
|
sed "s/HTTP_USER, \"value\": \"[^\"]*\"/HTTP_USER, \"value\": \"$KUBE_USER\"/g" \
|
||||||
"${KUBE_TEMP}/influx-grafana-pod.0.json" > "${KUBE_TEMP}/influx-grafana-pod.1.json"
|
"${KUBE_TEMP}/influx-grafana-pod.0.json" > "${KUBE_TEMP}/influx-grafana-pod.1.json"
|
||||||
sed "s/HTTP_PASS, \"value\": \"[^\"]*\"/HTTP_PASS, \"value\": \"$KUBE_PASSWORD\"/g" \
|
sed "s/HTTP_PASS, \"value\": \"[^\"]*\"/HTTP_PASS, \"value\": \"$KUBE_PASSWORD\"/g" \
|
||||||
"${KUBE_TEMP}/influx-grafana-pod.1.json" > "${KUBE_TEMP}/influx-grafana-pod.2.json"
|
"${KUBE_TEMP}/influx-grafana-pod.1.json" > "${KUBE_TEMP}/influx-grafana-pod.2.json"
|
||||||
local kubectl="${KUBE_ROOT}/cluster/kubectl.sh"
|
local kubectl="${KUBE_ROOT}/cluster/kubectl.sh"
|
||||||
if "${kubectl}" create -f "${KUBE_TEMP}/influx-grafana-pod.2.json" &> /dev/null \
|
if "${kubectl}" create -f "${KUBE_TEMP}/influx-grafana-pod.2.json" &> /dev/null \
|
||||||
&& "${kubectl}" create -f "${KUBE_ROOT}/examples/monitoring/influx-grafana-service.json" &> /dev/null \
|
&& "${kubectl}" create -f "${KUBE_ROOT}/examples/monitoring/influx-grafana-service.json" &> /dev/null \
|
||||||
@ -604,7 +601,7 @@ function setup-monitoring {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function teardown-monitoring {
|
function teardown-monitoring {
|
||||||
if [[ "${MONITORING}" == "true" ]]; then
|
if [[ "${ENABLE_CLUSTER_MONITORING}" == "true" ]]; then
|
||||||
detect-project
|
detect-project
|
||||||
|
|
||||||
local kubectl="${KUBE_ROOT}/cluster/kubectl.sh"
|
local kubectl="${KUBE_ROOT}/cluster/kubectl.sh"
|
||||||
@ -613,9 +610,9 @@ function teardown-monitoring {
|
|||||||
"${kubectl}" delete services influx-master &> /dev/null || true
|
"${kubectl}" delete services influx-master &> /dev/null || true
|
||||||
if gcloud compute firewall-rules describe monitoring-heapster &> /dev/null; then
|
if gcloud compute firewall-rules describe monitoring-heapster &> /dev/null; then
|
||||||
gcloud compute firewall-rules delete \
|
gcloud compute firewall-rules delete \
|
||||||
--project "${PROJECT}" \
|
--project "${PROJECT}" \
|
||||||
--quiet \
|
--quiet \
|
||||||
monitoring-heapster &> /dev/null || true
|
monitoring-heapster &> /dev/null || true
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
@ -37,3 +37,10 @@ MINION_TAG="tags=${INSTANCE_PREFIX}-minion"
|
|||||||
MINION_NAMES=($(eval echo ${INSTANCE_PREFIX}-minion-{1..${RAX_NUM_MINIONS}}))
|
MINION_NAMES=($(eval echo ${INSTANCE_PREFIX}-minion-{1..${RAX_NUM_MINIONS}}))
|
||||||
KUBE_NETWORK=($(eval echo "10.240.{1..${RAX_NUM_MINIONS}}.0/24"))
|
KUBE_NETWORK=($(eval echo "10.240.{1..${RAX_NUM_MINIONS}}.0/24"))
|
||||||
PORTAL_NET="10.0.0.0/16"
|
PORTAL_NET="10.0.0.0/16"
|
||||||
|
|
||||||
|
# Optional: Install node monitoring.
|
||||||
|
ENABLE_NODE_MONITORING=true
|
||||||
|
|
||||||
|
# Optional: Enable node logging.
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch
|
||||||
|
@ -184,6 +184,9 @@ rax-boot-minions() {
|
|||||||
sed -e "s|DISCOVERY_ID|${DISCOVERY_ID}|" \
|
sed -e "s|DISCOVERY_ID|${DISCOVERY_ID}|" \
|
||||||
-e "s|INDEX|$((i + 1))|g" \
|
-e "s|INDEX|$((i + 1))|g" \
|
||||||
-e "s|CLOUD_FILES_URL|${RELEASE_TMP_URL//&/\&}|" \
|
-e "s|CLOUD_FILES_URL|${RELEASE_TMP_URL//&/\&}|" \
|
||||||
|
-e "s|ENABLE_NODE_MONITORING|${ENABLE_NODE_MONITORING:-false}|" \
|
||||||
|
-e "s|ENABLE_NODE_LOGGING|${ENABLE_NODE_LOGGING:-false}|" \
|
||||||
|
-e "s|LOGGING_DESTINATION|${LOGGING_DESTINATION:-}|" \
|
||||||
$(dirname $0)/rackspace/cloud-config/minion-cloud-config.yaml > $KUBE_TEMP/minion-cloud-config-$(($i + 1)).yaml
|
$(dirname $0)/rackspace/cloud-config/minion-cloud-config.yaml > $KUBE_TEMP/minion-cloud-config-$(($i + 1)).yaml
|
||||||
|
|
||||||
|
|
||||||
|
@ -8,12 +8,16 @@ base:
|
|||||||
- docker
|
- docker
|
||||||
- kubelet
|
- kubelet
|
||||||
- kube-proxy
|
- kube-proxy
|
||||||
|
{% if pillar['enable_node_monitoring'] is defined and pillar['enable_node_monitoring'] %}
|
||||||
- cadvisor
|
- cadvisor
|
||||||
{% if pillar['use-fluentd-es'] is defined and pillar['use-fluentd-es'] %}
|
|
||||||
- fluentd-es
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if pillar['use-fluentd-gcp'] is defined and pillar['use-fluentd-gcp'] %}
|
{% if pillar['enable_node_logging'] is defined and pillar['enable_node_logging'] %}
|
||||||
|
{% if pillar['logging_destination'] is defined and pillar['logging_destination'] == 'elasticsearch' %}
|
||||||
|
- fluentd-es
|
||||||
|
{% endif %}
|
||||||
|
{% if pillar['logging_destination'] is defined and pillar['logging_destination'] == 'gcp' %}
|
||||||
- fluentd-gcp
|
- fluentd-gcp
|
||||||
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
- logrotate
|
- logrotate
|
||||||
{% if grains['cloud'] is defined and grains['cloud'] == 'azure' %}
|
{% if grains['cloud'] is defined and grains['cloud'] == 'azure' %}
|
||||||
|
@ -37,3 +37,10 @@ for ((i=0; i < NUM_MINIONS; i++)) do
|
|||||||
MINION_NAMES[$i]="${MINION_IP[$i]}"
|
MINION_NAMES[$i]="${MINION_IP[$i]}"
|
||||||
VAGRANT_MINION_NAMES[$i]="minion-$[$i+1]"
|
VAGRANT_MINION_NAMES[$i]="minion-$[$i+1]"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Optional: Install node monitoring.
|
||||||
|
ENABLE_NODE_MONITORING=true
|
||||||
|
|
||||||
|
# Optional: Enable node logging.
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch
|
||||||
|
@ -82,6 +82,9 @@ mkdir -p /srv/salt-overlay/pillar
|
|||||||
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
||||||
portal_net: $PORTAL_NET
|
portal_net: $PORTAL_NET
|
||||||
cert_ip: $MASTER_IP
|
cert_ip: $MASTER_IP
|
||||||
|
enable_node_monitoring: $ENABLE_NODE_MONITORING
|
||||||
|
enable_node_logging: $ENABLE_NODE_LOGGING
|
||||||
|
logging_destination: $LOGGING_DESTINATION
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
# Configure the salt-master
|
# Configure the salt-master
|
||||||
|
@ -32,3 +32,10 @@ MINION_MEMORY_MB=2048
|
|||||||
MINION_CPU=1
|
MINION_CPU=1
|
||||||
|
|
||||||
PORTAL_NET="10.244.240.0/20"
|
PORTAL_NET="10.244.240.0/20"
|
||||||
|
|
||||||
|
# Optional: Install node monitoring.
|
||||||
|
ENABLE_NODE_MONITORING=true
|
||||||
|
|
||||||
|
# Optional: Enable node logging.
|
||||||
|
ENABLE_NODE_LOGGING=true
|
||||||
|
LOGGING_DESTINATION=elasticsearch
|
||||||
|
@ -22,6 +22,9 @@ mkdir -p /srv/salt-overlay/pillar
|
|||||||
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
cat <<EOF >/srv/salt-overlay/pillar/cluster-params.sls
|
||||||
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
node_instance_prefix: $NODE_INSTANCE_PREFIX
|
||||||
portal_net: $PORTAL_NET
|
portal_net: $PORTAL_NET
|
||||||
|
enable_node_monitoring: $ENABLE_NODE_MONITORING
|
||||||
|
enable_node_logging: $ENABLE_NODE_LOGGING
|
||||||
|
logging_destination: $LOGGING_DESTINATION
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
mkdir -p /srv/salt-overlay/salt/nginx
|
mkdir -p /srv/salt-overlay/salt/nginx
|
||||||
|
@ -291,6 +291,9 @@ function kube-up {
|
|||||||
echo "readonly MASTER_NAME='${MASTER_NAME}'"
|
echo "readonly MASTER_NAME='${MASTER_NAME}'"
|
||||||
echo "readonly NODE_INSTANCE_PREFIX='${INSTANCE_PREFIX}-minion'"
|
echo "readonly NODE_INSTANCE_PREFIX='${INSTANCE_PREFIX}-minion'"
|
||||||
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
echo "readonly PORTAL_NET='${PORTAL_NET}'"
|
||||||
|
echo "readonly ENABLE_NODE_MONITORING='${ENABLE_NODE_MONITORING:-false}'"
|
||||||
|
echo "readonly ENABLE_NODE_LOGGING='${ENABLE_NODE_LOGGING:-false}'"
|
||||||
|
echo "readonly LOGGING_DESTINATION='${LOGGING_DESTINATION:-}'"
|
||||||
echo "readonly SERVER_BINARY_TAR='${SERVER_BINARY_TAR##*/}'"
|
echo "readonly SERVER_BINARY_TAR='${SERVER_BINARY_TAR##*/}'"
|
||||||
echo "readonly SALT_TAR='${SALT_TAR##*/}'"
|
echo "readonly SALT_TAR='${SALT_TAR##*/}'"
|
||||||
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
echo "readonly MASTER_HTPASSWD='${htpasswd}'"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# Makefile for a synthetic logger to be logged
|
# Makefile for a synthetic logger to be logged
|
||||||
# by GCP. The cluster must have been created with
|
# by GCP. The cluster must have been created with
|
||||||
# the environment variable FLUENTD_GCP set to 'true'.
|
# the variable LOGGING_DESTINATION=GCP.
|
||||||
|
|
||||||
.PHONY: up down logger-up logger-down get
|
.PHONY: up down logger-up logger-down get
|
||||||
|
|
||||||
|
@ -5,11 +5,15 @@
|
|||||||
### Logging with Fluentd and Elastiscsearch
|
### Logging with Fluentd and Elastiscsearch
|
||||||
|
|
||||||
To enable logging of the stdout and stderr output of every Docker container in
|
To enable logging of the stdout and stderr output of every Docker container in
|
||||||
a Kubernetes cluster set the shell environment
|
a Kubernetes cluster set the shell environment variables
|
||||||
variable ``FLUENTD_ELASTICSEARCH`` to ``true`` e.g. in bash:
|
``ENABLE_NODE_LOGGING`` to ``true`` and ``LOGGING_DESTINATION`` to ``elasticsearch``.
|
||||||
|
|
||||||
|
e.g. in bash:
|
||||||
```
|
```
|
||||||
export FLUENTD_ELASTICSEARCH=true
|
export ENABLE_NODE_LOGGING=true
|
||||||
|
export LOGGING_DESTINATION=elasticsearch
|
||||||
```
|
```
|
||||||
|
|
||||||
This will instantiate a [Fluentd](http://www.fluentd.org/) instance on each node which will
|
This will instantiate a [Fluentd](http://www.fluentd.org/) instance on each node which will
|
||||||
collect all the Dcoker container log files. The collected logs will
|
collect all the Dcoker container log files. The collected logs will
|
||||||
be targetted at an [Elasticsearch](http://www.elasticsearch.org/) instance assumed to be running on the
|
be targetted at an [Elasticsearch](http://www.elasticsearch.org/) instance assumed to be running on the
|
||||||
@ -20,4 +24,5 @@ Elasticsearch service (more informaiton to follow shortly in the contrib directo
|
|||||||
### Logging with Fluentd and Google Compute Platform
|
### Logging with Fluentd and Google Compute Platform
|
||||||
|
|
||||||
To enable logging of Docker contains in a cluster using Google Compute
|
To enable logging of Docker contains in a cluster using Google Compute
|
||||||
Platform set the shell environment variable ``FLUENTD_GCP`` to ``true``.
|
Platform set the config flags ``ENABLE_NODE_LOGGING`` to ``true`` and
|
||||||
|
``LOGGING_DESTINATION`` to ``gcp``.
|
||||||
|
Loading…
Reference in New Issue
Block a user