Welcome to the Linux Foundation Forum!

Lab setup: "ERROR: The Compose file './docker/docker-compose-ca.yaml' is invalid"

At the very last step of the lab setup, I get the error above trying to start the test network. Anyone else seeing this?

Answers

  • king612
    king612 Posts: 18

    I noticed that one of the steps in the setup procedure may be wrong. It says:

    "In the fabric-samples, checkout to the v2.2.2 tag.

    cd fabric-samples

    git checkout v2.2.2"

    This results in a detached head because the 'tag' argument is not used properly

    Everything seems to have come down properly either way, so I guess it doesn't matter since I won't be changing any code in here?

    Still can't get the test network to come up. The full error is:


    [email protected]:~/go/src/github.com/hyperledger/fabric-samples/test-network$ sudo ./network.sh up createChannel -ca -s couchdb
    [sudo] password for jking: 
    Creating channel 'mychannel'.
    If network is not up, starting nodes with CLI timeout of '5' tries and CLI delay of '3' seconds and using database 'couchdb with crypto from 'Certificate Authorities'
    Bringing up network
    Unable to find image 'hyperledger/fabric-tools:latest' locally
    docker: Error response from daemon: manifest for hyperledger/fabric-tools:latest not found: manifest unknown: manifest unknown.
    See 'docker run --help'.
    LOCAL_VERSION=2.2.2
    DOCKER_IMAGE_VERSION=
    Local fabric binaries and docker images are out of  sync. This may cause problems.
    CA_LOCAL_VERSION=1.4.9
    CA_DOCKER_IMAGE_VERSION=1.4.9
    Generating certificates using Fabric CA
    ERROR: The Compose file './docker/docker-compose-ca.yaml' is invalid because:
    networks.test value Additional properties are not allowed ('name' was unexpected)
    

    I tried commenting out the line with the 'name' property, and it got further, but ultimately failed again with the same error.

    I am blocked on this and cannot continue the course until I get a solution

    Thanks,
    John

  • king612
    king612 Posts: 18

    With the -name commented out in the ca yaml, I noticed this in the console logging:

    Bringing up network
    Unable to find image 'hyperledger/fabric-tools:latest' locally
    docker: Error response from daemon: manifest for hyperledger/fabric-tools:latest not found: manifest unknown: manifest unknown.
    See 'docker run --help'.
    LOCAL_VERSION=2.2.2
    DOCKER_IMAGE_VERSION=
    Local fabric binaries and docker images are out of sync. This may cause problems.

    After checking out everything from git, I do not have a hyperledger/fabric-tools directory...

  • basilky
    basilky Posts: 6

    Changing the version property to 3.7 in the docker-compose files resolved this issue for me.

  • moonishid
    moonishid Posts: 1

    @king612 That's because there is no "latest" tag in hyperledger/fabric-tools image on the public docker Hub. You can find all available tags of fabric-tools int below link.

    https://hub.docker.com/r/hyperledger/fabric-tools/tags

    Choose one available tag and modify "docker-compose-test-net.yaml". For example:
    ......
    cli:
    container_name: cli
    image: hyperledger/fabric-tools:2.4
    ......

    Further information can be found below link.

    https://stackoverflow.com/questions/43830372/error-manifest-for-hyperledger-fabric-ordererlatest-not-found

  • It's a problem with the docker-compose version you get with sudo apt install -y docker-compose follow the docker-compose installation guide to get the latest stable version of docker-compose to resolve the error https://docs.docker.com/compose/install/

  • Bobbijn
    Bobbijn Posts: 134

    @jason_dorman Thank you for posting this information. Getting the correct version of Docker-compose running is vital for the success of the labs, your post will help other learners resolve this issue. Bobbi

  • rashtrakoff
    rashtrakoff Posts: 2

    @jason_dorman said:
    It's a problem with the docker-compose version you get with sudo apt install -y docker-compose follow the docker-compose installation guide to get the latest stable version of docker-compose to resolve the error https://docs.docker.com/compose/install/

    I followed the link you provided but now I get this error:

    ./network.sh: line 182: docker-compose: command not found

    Any idea what I might have done wrong? docker compose version shows the correct version though.

  • rashtrakoff
    rashtrakoff Posts: 2

    @basilky said:
    Changing the version property to 3.7 in the docker-compose files resolved this issue for me.

    Yes, this worked for me as well. Thanks!

  • Bobbijn
    Bobbijn Posts: 134

    Great to see this group working together, keep on learning.

  • king612
    king612 Posts: 18

    @rashtrakoff said:

    @jason_dorman said:
    It's a problem with the docker-compose version you get with sudo apt install -y docker-compose follow the docker-compose installation guide to get the latest stable version of docker-compose to resolve the error https://docs.docker.com/compose/install/

    I followed the link you provided but now I get this error:

    ./network.sh: line 182: docker-compose: command not found

    Any idea what I might have done wrong? docker compose version shows the correct version though.

    I followed the instructions, but they all seemed to lead me back to installing docker desktop. Did that, but when I go to my apps menu it doesn't show up. Also, the installation appears to have been successful:

    Preparing to unpack .../docker-compose-plugin_2.6.0~ubuntu-focal_amd64.deb ...
    Unpacking docker-compose-plugin (2.6.0~ubuntu-focal) ...
    Setting up docker-compose-plugin (2.6.0~ubuntu-focal) ...
    [email protected]:~$ sudo docker run hello-world

    Hello from Docker!
    This message shows that your installation appears to be working correctly.

    However, docker-compose doesn't run from the command line:

    [email protected]:~$ sudo docker-compose --version
    [sudo] password for jking:
    sudo: docker-compose: command not found
    [email protected]:~$

    Do I need to restart the VM?

    Pls help - I've been blocked on docker-compose issue for some time now.

  • king612
    king612 Posts: 18

    @rashtrakoff Did you use the Docker Desktop alternative listed on that page to install Compose? The DEB version is for amd64 but I'm running Oracle VirtualBox on a Mac OS (intel chip). Not sure which version of the Docker Desktop I should be installing in this case.

  • king612
    king612 Posts: 18

    I finally got this to work user Docker Desktop for Ubuntu (the amd64 version works).

    NOTE: The instructions have (another) typo: to get the docker compose version after installing this way, you have to do this:
    $ docker compose version

    (the instructions say $ docker-compose --version which fails)

  • Bobbijn
    Bobbijn Posts: 134

    @King612, Thank you for spotting this typo. We will be editing the documentation shortly. Bobbi

Categories

Upcoming Training