Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing Docker Compose? #397

Open
melroy89 opened this issue Feb 12, 2024 · 4 comments · May be fixed by #462
Open

Missing Docker Compose? #397

melroy89 opened this issue Feb 12, 2024 · 4 comments · May be fixed by #462

Comments

@melroy89
Copy link

melroy89 commented Feb 12, 2024

I'm using Docker Compose v3 with Synapse (matrixdotorg/synapse) as well.

I think it would be very valuable to provide an example docker compose for sliding sync Docker image. Allowing server admins to easily get sliding-sync up and running.

My proposal is to just add an example compose yaml file to the git repo.

@Domoel
Copy link

Domoel commented Feb 24, 2024

I used this:

version: "3"

services:

sliding-proxy:
image: ghcr.io/matrix-org/sliding-sync:v0.99.1
restart: unless-stopped
ports:
- "127.0.0.1:8881:8881"
environment:
- "SYNCV3_SECRET="
- "SYNCV3_SERVER=DOMAIN.ltd
- "SYNCV3_DB=user=syncv3 dbname=syncv3 sslmode=disable host=sliding-postgres password=hunter2"
- "SYNCV3_BINDADDR=0.0.0.0:8881"
depends_on:
- sliding-postgres
networks:
- synapse_default

sliding-postgres:
image: docker.io/postgres:15-alpine
restart: unless-stopped
environment:
- "POSTGRES_USER=syncv3"
- "POSTGRES_PASSWORD=hunter2"
- "POSTGRES_DB=syncv3"
volumes:
- /volume2/docker/slidingsync/sliding_db_data:/var/lib/postgresql/data
networks:
- synapse_default

volumes:
sliding_db_data:

networks:
synapse_default:
external: true
name: synapse_default

@melroy89
Copy link
Author

You might want to add your example in a markdown code block.

Anyhow. I think such an example should be added to the git repo.

@vahtos
Copy link

vahtos commented Aug 29, 2024

I needed to convert the instructions to docker-compose too. Here's the formatted version of the above comment, with some typos corrected and deprecated version line removed.

services:
  sliding-proxy:
    image: ghcr.io/matrix-org/sliding-sync:v0.99.1
    restart: unless-stopped
    ports:
      - "127.0.0.1:8881:8881"
    environment:
      - "SYNCV3_SECRET="
      - "SYNCV3_SERVER=DOMAIN.tld"
      - "SYNCV3_DB=user=syncv3 dbname=syncv3 sslmode=disable host=sliding-postgres password=hunter2"
      - "SYNCV3_BINDADDR=0.0.0.0:8881"
    depends_on:
      - sliding-postgres
    networks:
      - synapse_default

  sliding-postgres:
    image: docker.io/postgres:15-alpine
    restart: unless-stopped
    environment:
      - "POSTGRES_USER=syncv3"
      - "POSTGRES_PASSWORD=hunter2"
      - "POSTGRES_DB=syncv3"
    volumes:
      - /volume2/docker/slidingsync/sliding_db_data:/var/lib/postgresql/data
    networks:
      - synapse_default

volumes:
  sliding_db_data:

networks:
  synapse_default:
    external: true
    name: synapse_default

@melroy89
Copy link
Author

melroy89 commented Sep 4, 2024

I needed to convert the instructions to docker-compose too. Here's the formatted version of the above comment, with some typos corrected and deprecated version line removed.

services:
  sliding-proxy:
    image: ghcr.io/matrix-org/sliding-sync:v0.99.1
    restart: unless-stopped
    ports:
      - "127.0.0.1:8881:8881"
    environment:
      - "SYNCV3_SECRET="
      - "SYNCV3_SERVER=DOMAIN.tld"
      - "SYNCV3_DB=user=syncv3 dbname=syncv3 sslmode=disable host=sliding-postgres password=hunter2"
      - "SYNCV3_BINDADDR=0.0.0.0:8881"
    depends_on:
      - sliding-postgres
    networks:
      - synapse_default

  sliding-postgres:
    image: docker.io/postgres:15-alpine
    restart: unless-stopped
    environment:
      - "POSTGRES_USER=syncv3"
      - "POSTGRES_PASSWORD=hunter2"
      - "POSTGRES_DB=syncv3"
    volumes:
      - /volume2/docker/slidingsync/sliding_db_data:/var/lib/postgresql/data
    networks:
      - synapse_default

volumes:
  sliding_db_data:

networks:
  synapse_default:
    external: true
    name: synapse_default

Thanks. Create a PR Plz ;)

@vahtos vahtos linked a pull request Sep 6, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants