mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
The idea is to import/dump the remote database via SSH, restore it to the local mongodb, export .json collections to a shared volume and import the json collections with cypher-shell.
43 lines
1.0 KiB
YAML
43 lines
1.0 KiB
YAML
version: "3.7"
|
|
|
|
services:
|
|
backend:
|
|
image: humanconnection/nitro-backend:builder
|
|
build:
|
|
context: .
|
|
target: builder
|
|
volumes:
|
|
- .:/nitro-backend
|
|
- /nitro-backend/node_modules
|
|
command: yarn run dev
|
|
neo4j:
|
|
volumes:
|
|
- mongo-export:/mongo-export
|
|
ports:
|
|
- 7687:7687
|
|
- 7474:7474
|
|
environment:
|
|
- NEO4J_apoc_import_file_enabled=true
|
|
db-migration-worker:
|
|
build:
|
|
context: db-migration-worker
|
|
args:
|
|
- "KNOWN_HOST=${SSH_HOST}"
|
|
volumes:
|
|
- mongo-export:/mongo-export
|
|
networks:
|
|
- hc-network
|
|
environment:
|
|
- "SSH_USERNAME=${SSH_USERNAME}"
|
|
- "SSH_HOST=${SSH_HOST}"
|
|
- "MONGODB_USERNAME=${MONGODB_USERNAME}"
|
|
- "MONGODB_PASSWORD=${MONGODB_PASSWORD}"
|
|
- "MONGODB_AUTH_DB=${MONGODB_AUTH_DB}"
|
|
- "MONGODB_DATABASE=${MONGODB_DATABASE}"
|
|
- "NEO4J_USERNAME=${NEO4J_USERNAME}"
|
|
- "NEO4J_PASSWORD=${NEO4J_PASSWORD}"
|
|
command: "--smallfiles --logpath=/dev/null"
|
|
|
|
volumes:
|
|
mongo-export:
|