Speckle Deployment: Update of Docker-Compose YAML produced some errors

Hello dear Specklers,

I have modified the Docker-Compose file to fit your latest configuration from here:
Deploying a Server - manual setup | Speckle Docs

The version 3.9 resulted in the following error message

ERROR: Version in "./docker-compose.yml" is unsupported. You might be seeing this error because you're using the wrong Compose file version. Either specify a supported version (e.g "2.2" or "3.3") and place your service definitions under the `services` key, or omit the `version` key and place your service definitions at the root of the file to use version 1.
For more on the Compose file format versions, see https://docs.docker.com/compose/compose-file/

I have modified it to version 3.0 which works. It is strange as we should have the latest setup on our machine.

With version 3.0 I had the following issues:

  • The healthcheck lines for everything except of the servers resulted in error messages → commented it out
  • The memlimit and memswap of the preview service resulted in issues → commented it out
  • Network resulted in issues to … was not there in my initial yaml … also dashed for now

After that the server works. Maybe there is an easy solution for that

admin-speckle@VM-DF-SpeckleV2:/opt/speckle$ sudo docker-compose up -d
ERROR: The Compose file './docker-compose.yml' is invalid because:
Unsupported config option for services.preview-service: 'mem_limit'
networks.default value Additional properties are not allowed ('name' was unexpected)
services.fileimport-service.depends_on contains an invalid type, it should be an array
services.preview-service.depends_on contains an invalid type, it should be an array
services.webhook-service.depends_on contains an invalid type, it should be an array
admin-speckle@VM-DF-SpeckleV2:/opt/speckle$ sudo docker-compose up -d
ERROR: The Compose file './docker-compose.yml' is invalid because:
Unsupported config option for services.preview-service: 'memswap_limit'
networks.default value Additional properties are not allowed ('name' was unexpected)
services.fileimport-service.depends_on contains an invalid type, it should be an array
services.preview-service.depends_on contains an invalid type, it should be an array
services.webhook-service.depends_on contains an invalid type, it should be an array
admin-speckle@VM-DF-SpeckleV2:/opt/speckle$ sudo docker-compose up -d
ERROR: The Compose file './docker-compose.yml' is invalid because:
Unsupported config option for services.preview-service: 'memswap_limit'
admin-speckle@VM-DF-SpeckleV2:/opt/speckle$ sudo docker-compose up -d
ERROR: The Compose file './docker-compose.yml' is invalid because:
Unsupported config option for services.preview-service: 'memswap_limit'
admin-speckle@VM-DF-SpeckleV2:/opt/speckle$ sudo docker-compose up -d
ERROR: The Compose file './docker-compose.yml' is invalid because:
Unsupported config option for services.preview-service: 'mem_limit'

Thanks for your support :slight_smile:

Best,
Alex

Hey @AlexHofbeck

i think we’ve accidentally specified a bad compose file version in the docs. As @iainsproat fixed in the server fix(docker compose): must use 2.3 as we have features removed in 3 by iainsproat · Pull Request #1679 · specklesystems/speckle-server · GitHub
we need to pin the compose file version to ~2 until we figure out what and how we need to migrate.

I’ve fixed our docs, to suggest 2.3 for now, which is a version that is working for me. Thanks for the report.

Hope this fixes it for u

2 Likes

Did the trick :slight_smile: ! Thanks @gjedlicska.

1 Like

Sorry about that! We require version >=2.3 in order to support HealthChecks in Docker Compose.
I took the opportunity to try to upgrade to the latest version, 3.9, but encountered the same error due to the differences between v2.x and v3.x. I reverted the code to v2.3 but forgot about doing the same for the documentation!

Thanks for reporting @AlexHofbeck, and thanks for fixing @gjedlicska. As @gjedlicska says, we need to figure out the migration strategy for eventually moving to v3.x in due course.

2 Likes