CATCHV Blog

consol stand alone config 본문

기타

consol stand alone config

catchv 2023. 8. 28. 09:28
반응형

consul agent를 dev모드로 실행시 

data_dir 에 데이터가 저장되지 않습니다.

해당 설정으로 stand alone 모드로 실행시 데이터의 저장이 가능합니다.

{
    "node_name": "consul-server1",
    "datacenter": "dc",
    "server": true,
    "ui_config": {
      "enabled": true
    },
    "data_dir": "/consul/data",
    "addresses": {
      "http": "0.0.0.0"
    },
    "bootstrap_expect":1,
    "encrypt": "aPuGh+5UDskRAbkLaXRzFoSOcSM+5vAK+NEYOWHJH7w=",
    "auto_encrypt": {
      "allow_tls": true
    },
    
    "verify_incoming": false,
    "verify_incoming_rpc": false,
    "verify_outgoing": false,
    "verify_server_hostname": false
  }

 

docker를 사용할 경우 agent 옵션에 -config-dir command를 전달 할 수 있습니다.

command: "agent -config-dir=/consul/config/config.json"
반응형
Comments