Skip to content

Triton example in the README.md fails #51

Open

Description

@jantoine1

While following the example in the README.md file, after all three consul containers are up and running, the logs are full of the following messages and are repeated indefinitely:

consul_3 | 2018-04-18T22:48:57.476823000Z 2018/04/18 22:48:57 /usr/local/bin/consul-manage: line 19: [: ==: unary operator expected
consul_3 | 2018-04-18T22:48:57.483049000Z 2018/04/18 22:48:57 Service registration failed: Put http://127.0.0.1:8500/v1/agent/service/register: dial tcp 127.0.0.1:8500: connect: connection refused
consul_1 | 2018-04-18T22:49:01.817519000Z 2018/04/18 22:49:01 /usr/local/bin/consul-manage: line 19: [: ==: unary operator expected
consul_1 | 2018-04-18T22:49:01.822914000Z 2018/04/18 22:49:01 Service registration failed: Put http://127.0.0.1:8500/v1/agent/service/register: dial tcp 127.0.0.1:8500: getsockopt: connection refused
consul_2 | 2018-04-18T22:49:02.884224000Z 2018/04/18 22:49:02 /usr/local/bin/consul-manage: line 19: [: ==: unary operator expected
consul_2 | 2018-04-18T22:49:02.886316000Z 2018/04/18 22:49:02 Service registration failed: Put http://127.0.0.1:8500/v1/agent/service/register: dial tcp 127.0.0.1:8500: connect: connection refused

Steps to reproduce

  1. git clone https://github.com/autopilotpattern/consul.git
  2. cd consul/example/triton
  3. eval "$(triton env)"
  4. ./setup.sh
  5. docker-compose up -d
  6. docker-compose scale consul=3
  7. docker-compose logs -ft

Let me know if I can provide any additional information.

Activity

  1. jantoine1 commented on Apr 19, 2018

    @jantoine1
    Author

    The underlying issue causing this problem was that even though I had told Triton to use the 'autopilotpattern/consul:latest' image to build the consul containers from, and it did pull down the latest autopilotpattern/consul image into my Triton account, it was using an old 'autopilotpattern/consul' image from 6 months ago that also had the 'latest' tag associated with it. This seems like a bug with docker image management within Triton?

    Another issue that caused a point of confusion... When running the setup.sh script, I initially received the following error:

    Error! The Triton CLI configuration does not match the Docker CLI configuration.

    Docker user:
    Triton user: myuser
    Docker data center:
    Triton data center: us-west-1

    To resolve this issue, I ran step 3 from my original post: eval "$(triton env)". This caused me to be pointing at Triton both via Docker and Triton commands (docker, docker-compose, triton-docker and triton-compose). I believe this step is no longer necessary with the new Triton Docker CLI tool, am I wrong?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions