diff --git a/docker-compose.typesense.yaml b/docker-compose.typesense.yaml index b47825e..4d0f0b7 100644 --- a/docker-compose.typesense.yaml +++ b/docker-compose.typesense.yaml @@ -1,16 +1,32 @@ #ddev-generated services: - addon-template: + typesense: container_name: ddev-${DDEV_SITENAME}-typesense hostname: ${DDEV_SITENAME}-typesense image: typesense/typesense:0.25.1 command: '--data-dir /data --api-key=test --enable-cors' networks: [default, ddev_default] restart: "no" + environment: + - VIRTUAL_HOST=$DDEV_HOSTNAME ports: - "8108:8108" labels: com.ddev.site-name: ${DDEV_SITENAME} com.ddev.approot: $DDEV_APPROOT volumes: - - "./typesense-data:/data" + - "typesense:/data" + - ".:/mnt/ddev_config" + typesense_admin: + container_name: typesense_admin + image: ghcr.io/lewynation/typesense-admin-dashboard:latest + restart: always + ports: + - "3005:3000" + external_links: + - "ddev-router:${DDEV_SITENAME}.${DDEV_TLD}" +volumes: + # typesense is a persistent Docker volume for typesense data + # The persistent volume should have the same name as the service so it can be deleted + # when the project is deleted. + typesense: \ No newline at end of file diff --git a/install.yaml b/install.yaml index 4b02cef..6ed277a 100644 --- a/install.yaml +++ b/install.yaml @@ -1,10 +1,4 @@ name: typesense -pre_install_commands: - - mkdir $(DDEV_APPROOT)/typesense-data - project_files: - docker-compose.typesense.yaml - -removal_actions: - - rm $(DDEV_APPROOT)/typesense-data