go-cd

Can I check the agent's health on gocd-server page?


I want to display the agent's status instantly if it was disappeared.

enter image description here


    version: "2"
    services:
      gocd-server:
        container_name: gocd-server
        image: gocd/gocd-server-centos-7:v19.5.0
        ports:
          - '80:8153'
          - '8154:8154'
      gocd-agent1:
        container_name: panda
        image: gocd/gocd-agent-centos-7:v19.5.0
        environment:
          - GO_SERVER_URL=https://gocd-server:8154/go
        links:
          - gocd-server
      gocd-agent2:
        container_name: kitty
        image: gocd/gocd-agent-centos-7:v19.5.0
        environment:
          - GO_SERVER_URL=https://gocd-server:8154/go
        links:
          - gocd-server


Solution

  • If the server hasn't had contact with the agent for a while, the status will change to lost contact. But not immediately, and I don't think there's any other way to find out immediately.

    Usually you don't want small (seconds or sub-second) network glitches to show all of your agents as missing.