'docker-compose up ERROR: In file, services 'files' must be a mapping not an array

I'm trying to create and launch my first ever docker-compose.yml, but I get this error every time. I tried palying with indents, but nothing seems to help

Could you please, help me out?

files:
  - e2e.yml

default_recipe: "e2e"

recipes:
  e2e:
    files:
      - e2e.yml

This is the command I run:

docker-compose up
ERROR: In file './docker-compose.yml', services 'files' must be a mapping not an array.


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source