1. 建立乙個docker網路
docker network create fabric-ca
2. 編寫compose檔案,容器想要加入這個網路version: '2'
services:
ca-root:
image: hyperledger/fabric-ca:1.4
container_name: ca-root
ports:
- "7054:7054"
environment:
- fabric_ca_home=/etc/hyperledger/fabric-ca-server
volumes:
- "/root/fabric-ca/rootcaserver:/etc/hyperledger/fabric-ca-server"
command: sh -c 'fabric-ca-server start -b admin:adminpw --cfg.identities.allowremove --cfg.affiliations.allowremove'
networks:
- fabric-ca
3. 解決網路未定義問題version: '2'
networks:
fabric-ca:
external: true
services:
ca-root:
image: hyperledger/fabric-ca:1.4
container_name: ca-root
ports:
- "7054:7054"
environment:
- fabric_ca_home=/etc/hyperledger/fabric-ca-server
volumes:
- "/root/fabric-ca/rootcaserver:/etc/hyperledger/fabric-ca-server"
command: sh -c 'fabric-ca-server start -b admin:adminpw --cfg.identities.allowremove --cfg.affiliations.allowremove'
networks:
- fabric-ca
增加和service同級的networks標籤。並且在指定networks的時候,需要加乙個屬性:
external: true
mysql建立了索引但是leftjoin索引失效
select a.concat ws parent.name,b.name cityname,concat ws att.attachment name,attachment url attachment,c.name companyname,d.name typename,e.name stage...
docker 建立overlay網路實踐
參考文件 1 step 1 set up a key value store docker machine create driver generic generic ip address 192.168.153.222 generic ssh key ssh id rsa mh keystore ...
docker 環境下建立 overlay 網路方案
一.環境 三颱機器,其中一台安裝 consul 192.168.1.21 兩台建立網路 192.168.1.32,33 二.實現步驟 1.構建環境 1 三颱機器部署docker環境 2 選擇一台作為consul伺服器,安裝consul consul 為乙個key value資料庫用於儲存網路狀態資訊...