Last active
October 23, 2023 19:31
-
-
Save decima/7227520ac2c29e64f2565291ae05d50a to your computer and use it in GitHub Desktop.
Docker-compose for databases
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Here is a curated list of docker-compose for some databases I use. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Elasticsearch | |
--- | |
version: '3.7' | |
services: | |
es01: | |
image: docker.elastic.co/elasticsearch/elasticsearch:7.15.0 | |
environment: | |
- node.name=es01 | |
- discovery.type=single-node | |
- cluster.name=es-docker-cluster | |
- bootstrap.memory_lock=false | |
- xpack.security.enabled=false | |
- "ES_JAVA_OPTS=-Xms2048m -Xmx2048m" # Default max ram to 2Gb (should not be less) | |
ulimits: | |
memlock: | |
soft: -1 | |
hard: -1 | |
volumes: | |
- ./elasticsearch:/usr/share/elasticsearch/data # ES Storage | |
ports: | |
- 9200:9200 | |
networks: | |
- elastic | |
kib01: | |
image: docker.elastic.co/kibana/kibana:7.15.0 | |
ports: | |
- 5601:5601 | |
environment: | |
ELASTICSEARCH_URL: http://es01:9200 | |
ELASTICSEARCH_HOSTS: '["http://es01:9200"]' | |
networks: | |
- elastic | |
networks: | |
elastic: ~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
influxdb: | |
ports: | |
- "8086:8086" #Web API interface | |
image: influxdb:2.0.8 | |
volumes: | |
- ./influxdb2:/var/lib/influxdb2 #Storage path |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
mongo: | |
image: mongo:latest | |
environment: | |
MONGO_INITDB_ROOT_USERNAME: admin | |
MONGO_INITDB_ROOT_PASSWORD: admin | |
ports: | |
- "27017:27017" | |
- "/mongodb:/data/db" #local Mongo Storage | |
mongo-express: # Mongo Express service is for a Mongo UI Service. it's not required | |
image: mongo-express:latest | |
ports: | |
- 8081:8081 | |
environment: | |
ME_CONFIG_MONGODB_ADMINUSERNAME: admin | |
ME_CONFIG_MONGODB_ADMINPASSWORD: admin | |
ME_CONFIG_MONGODB_SERVER: mongo | |
ME_CONFIG_MONGODB_PORT: "27017" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
neo4j: | |
image: neo4j | |
ports: | |
- 7474:7474 # Web interface | |
- 7687:7687 # Bolt Interface | |
environment: | |
- NEO4J_dbms_security_procedures_unrestricted=apoc.* | |
- NEO4J_apoc_import_file_enabled=true | |
- NEO4J_dbms_shell_enabled=true | |
- NEO4J_AUTH=neo4j/password #username/password pair | |
- NEO4J_dbms_security_auth__minimum__password__length=4 | |
- NEO4J_dbms_connector_http_advertised__address=0.0.0.0:7474 | |
volumes: | |
- ./plugins:/plugins | |
- ./neo4j:/data | |
- ./import:/import # a simple access to import a lot of data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
db: | |
image: postgres | |
volumes: | |
- ./postgreSQL:/var/lib/postgresql/data #local PG Storage | |
environment: | |
- POSTGRES_DB=postgres # Default Database | |
- POSTGRES_USER=postgres # postgres Username | |
- POSTGRES_PASSWORD=postgres # postgres Password | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
redis: | |
image: redis:alpine | |
command: redis-server --appendonly yes #AppendOnly is for local data storage | |
volumes: | |
- ./redis:/data #./redis storage | |
ports: | |
- "6379:6379" | |
redisAdmin: # Redis Ad;in is a simple php interface | |
image: erikdubbelboer/phpredisadmin | |
ports: | |
- "8080:80" | |
environment: | |
REDIS_1_HOST: redis | |
REDIS_1_PORT: 6379 | |
REDIS_1_NAME: localhost |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment