some text
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
#cloud-config | |
coreos: | |
etcd: | |
# generate a new token for each unique cluster from https://discovery.etcd.io/new?size=3 | |
# specify the initial size of your cluster with ?size=X | |
discovery: https://discovery.etcd.io/token | |
# multi-region deployments, multi-cloud deployments, and droplets without | |
# private networking need to use $public_ipv4 | |
addr: $private_ipv4:4001 |
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
export SPM_TOKEN=YOUR_TOKEN_HERE | |
# Name two Elasticsearch nodes | |
export ES1="ES-1" | |
export ES2="ES-2" | |
# let's configure 2 nodes in this example | |
export SPM_CFG="${SPM_TOKEN} es javagent jvmname:${ES1};${SPM_TOKEN} es javagent jvmname:${ES2}" | |
docker run --name spm-client -e HOSTNAME=$HOSTNAME --restart=always -e SPM_CFG sematext/spm-client | |
# start the 2 Elasticsearch nodes, one exposes 9200 to the public | |
docker run --name $ES1 -h $ES1 p 9200:9200 -d --volumes-from spm-client -e ES_JAVA_OPTS="-Dcom.sun.management.jmxremote -javaagent:/opt/spm/spm-monitor/lib/spm-monitor-es.jar=${SPM_TOKEN}::${ES1} -es.node.name=${ES1}" elasticsearch |
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
wget https://download.elastic.co/kibana/kibana/kibana-4.2.0-linux-x64.tar.gz | |
cd kibana-4.2.0-linux-x64 | |
./bin/kibana plugin --install elastic/sense | |
echo -e "kibana.enabled: false # disable the standard kibana discovery, visualize & dashboard plugins\n | |
elasticsearch.enabled: false # do not require a running Elasticsearch 2.0 instance" >> config/kibana.yml | |
./bin/kibana |
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
curl -XPOST -H "Content-type: application/json" http://your_marathon_server:8080/v2/apps -d ' | |
{ | |
"container": { | |
"type": "DOCKER", | |
"docker": { | |
"image": "sematext/sematext-agent-docker" | |
}, | |
"volumes": [ | |
{ | |
"containerPath": "/var/run/docker.sock", |
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
export UUSER=seti123 | |
export UHOST=aldebaran.uberspace.de | |
cd ~/.ssh | |
ssh-keygen -t rsa -b 4096 -f uberspace_rsa4096 | |
cat ~/.ssh/uberspace_rsa4096.pub | ssh -p 4022 $UUSER@$UHOST 'cat >> .ssh/authorized_keys' | |
cat <<EOF >> ~/.ssh/config | |
Host $UHOST | |
Port 22 | |
IdentityFile ~/.ssh/uberspace_rsa4096 |
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
export SLACK_TOKEN=slack_token_here # https://api.slack.com/web | |
export LOGSENE_TOKEN=logsene_token_here # https://sematext.com/logsene | |
export LOGSENE_URL=https://logsene-receiver.sematext.com:443 | |
node ./slack.js $SLACK_TOKEN | logagent -t $LOGSENE_TOKEN |
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
apiVersion: extensions/v1beta1 | |
kind: DaemonSet | |
metadata: | |
name: sematext-agent | |
spec: | |
template: | |
metadata: | |
labels: | |
app: sematext-agent | |
spec: |
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
export SPM_TOKEN=TOUR_SPM_TOKEN | |
export LOGSENE_TOKEN=YOUR_LOGSENE_TOKEN | |
export NODES=$(docker-machine ls | grep Running | grep -v error | awk '{printf $1 "\t"}') | |
echo Swarm nodes: "$NODES" | |
for node in $NODES; do | |
echo "get docker-machine env $node" | |
eval "$(docker-machine env $node)" | |
echo "Using docker host: $DOCKER_HOST" | |
echo "deploy sematext-agent-docker to $node" | |
docker rm -f sematext-agent 2>1 /dev/null |
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
ServerRoot "/usr/local/apache2" | |
Listen 80 | |
LoadModule authn_file_module modules/mod_authn_file.so | |
LoadModule authn_core_module modules/mod_authn_core.so | |
LoadModule authz_host_module modules/mod_authz_host.so | |
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so | |
LoadModule authz_user_module modules/mod_authz_user.so | |
LoadModule authz_core_module modules/mod_authz_core.so | |
LoadModule access_compat_module modules/mod_access_compat.so | |
LoadModule auth_basic_module modules/mod_auth_basic.so |