Skip to content

Instantly share code, notes, and snippets.

View nimaafraz's full-sized avatar
🏠
Working from home

Nima Afraz nimaafraz

🏠
Working from home
View GitHub Profile
$curl -u admin:admin 0.0.0.0:9090
<a href="/graph">Found</a>.
$ docker ps
IMAGE COMMAND PORTS
stefanprodan/swarmprom-prometheus:v2.5.0 "/etc/prometheus/doc…" 9090/tcp
stefanprodan/swarmprom-grafana:5.3.4 "/run.sh" 3000/tcp
google/cadvisor:latest "/usr/bin/cadvisor -…" 8080/tcp
stefanprodan/caddy:latest "/sbin/tini -- caddy…"
stefanprodan/caddy:latest "/sbin/tini -- caddy…"
stefanprodan/swarmprom-alertmanager:v0.14.0 "/etc/alertmanager/d…" 9093/tcp
stefanprodan/swarmprom-node-exporter:v0.16.0 "/etc/node-exporter/…" 9100/tcp
$ git clone https://github.com/stefanprodan/swarmprom.git
$ cd swarmprom
$ ADMIN_USER=admin \
ADMIN_PASSWORD=admin \
SLACK_URL=https://hooks.slack.com/services/TOKEN \
SLACK_CHANNEL=devops-alerts \
SLACK_USER=alertmanager \
docker stack deploy -c docker-compose.yml mon
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
version: '2'
services:
ca.org2.example.com:
image: hyperledger/fabric-ca:1.4.0
environment:
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
- FABRIC_CA_SERVER_CA_NAME=ca.org2.example.com
- FABRIC_CA_SERVER_CA_CERTFILE=/etc/hyperledger/fabric-ca-server-config/ca.org2.example.com-cert.pem
version: '2'
services:
ca.org1.example.com:
image: hyperledger/fabric-ca:1.4.0
environment:
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
- FABRIC_CA_SERVER_CA_NAME=ca.org1.example.com
- FABRIC_CA_SERVER_CA_CERTFILE=/etc/hyperledger/fabric-ca-server-config/ca.org1.example.com-cert.pem
- FABRIC_CA_SERVER_CA_KEYFILE=/etc/hyperledger/fabric-ca-server-config/key.pem
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
npm run bench -- -c benchmark/simple/config-linear-rate.yaml -n network/fabric-v1.1/3org1peercouchdb/fabric-node.json
npm run bench -- -c benchmark/simple/config-linear-rate.yaml -n network/fabric-v1.1/dev/fabric-node.json