version: '3.4'

services:
  githubactionscreator:
    image: jianboy/springboot:latest
    build:
      context: .
      dockerfile: ./Dockerfile
    ports:
      - 3000:3000
    volumes:
      - hostPath:containerPath:ro

  mysql:
    image: mysql:5.7
    environment:
      MYSQL_ROOT_PASSWORD: root
      MYSQL_DATABASE: githubactionscreator
    ports:
      - 3306:3306

  redis:
    image: redis:latest
    ports:
      - 6379:6379
    
  h2:
    container_name: MyH2Instance
    image: oscarfonts/h2:latest
    ports:
      - 1521:1521
      - 81:81
    volumes:
      - $(pwd):/opt/h2-data
    environment:
      - H2_OPTIONS=-ifNotExists

networks:
  default:
    external:
      name: githubactionscreator