Unsupported config option for services.networks: 'ipam'

Viewed 2129

I trying to up my docker-compose file at docker-compose version 1.24.1, build 4667896.

This is my networks block of services:

version: "3"  
networks:
     name: atlassian_products   
     driver: bridge
     internal: false
     ipam:
       driver: default
       config: 
         - subnet: 100.127.255.0/24

When i run:

 $ sudo docker-compose up --remove-orphans --build --force-recreate -d

I return this error: ERROR: The Compose file './docker-compose.yml' is invalid because: Unsupported config option for services.networks: 'ipam'

What's wrong of this block? I am not able to figure out what is going on.

Thank you in advance!

1 Answers

It's the version. I had the same issue.

You have to use version 2.

Related