Compose.yaml

services:
  cassandra:
    image: 'cassandra:latest'
    container_name: 'cassandra-1'
    environment:
      - 'CASSANDRA_DC=datacenter1'
      - 'CASSANDRA_ENDPOINT_SNITCH=GossipingPropertyFileSnitch'
      - 'CASSANDRA_SEEDS=cassandra'  # Use the service name as the seed
    ports:
      - '9042:9042'

Atualizado