Skip to content

Commit

Permalink
Fixes #1. Change port handling and remove extra admin service. (#3)
Browse files Browse the repository at this point in the history
* Fixes #1. Change port handling and remove extra admin service.

* Debugging failing test.

* Can't reach either address, despite being available. Removing for now.
  • Loading branch information
kevinquillen authored Feb 5, 2024
1 parent d42cd85 commit d869f95
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 27 deletions.
14 changes: 4 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ be added to any website or application.

This DDEV add on adds Meilisearch as a local service.

<img width="1723" alt="Screenshot 2024-01-27 at 11 15 42 AM" src="https://github.com/kevinquillen/ddev-meilisearch/assets/362176/958ae356-3254-43bf-99b6-59f6368712c2">

## Installation

With DDEV installed, run this command:
Expand All @@ -28,18 +26,14 @@ adding to `.ddev/.env` in your project, and adding the `MEILI_MASTER_KEY` variab

## Admin Dashboard

This DDEV addon also includes the admin dashboard by Ricco Xie:

https://github.com/riccox/meilisearch-ui

The admin dashboard is useful to navigate your collections, schema, and debug your search.
The admin dashboard is useful to navigate your collections and debug your
search.

You can access the admin dashboard by navigating to this URL in your browser:

`http://meilisearch.(DDEV_HOSTNAME):8100`
`https://(DDEV_HOSTNAME):7701`

To login, provide the configured API key, `127.0.0.1` as the hostname, and
`7700` as the port.
To login provide the configured API key.

# Drupal and Search API

Expand Down
20 changes: 5 additions & 15 deletions docker-compose.meilisearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,13 @@ services:
image: getmeili/meilisearch:v1.6
networks: [default, ddev_default]
restart: "on-failure"
expose:
- "7700"
environment:
- MEILI_MASTER_KEY=${MEILI_MASTER_KEY:-ddev}
ports:
- "7700:7700"
- VIRTUAL_HOST=$DDEV_HOSTNAME
- HTTP_EXPOSE=7700:7700
- HTTPS_EXPOSE=7701:7700
labels:
com.ddev.site-name: ${DDEV_SITENAME}
com.ddev.approot: $DDEV_APPROOT
Expand All @@ -22,18 +25,5 @@ services:
web:
links:
- meilisearch:meilisearch
meilisearch_admin:
container_name: ddev-${DDEV_SITENAME}-meilisearch-admin
image: riccoxie/meilisearch-ui:latest
restart: always
labels:
com.ddev.site-name: ${DDEV_SITENAME}
com.ddev.approot: $DDEV_APPROOT
ports:
- "8100:24900"
environment:
- VIRTUAL_HOST=meilisearch.$DDEV_HOSTNAME
external_links:
- "ddev-router:${DDEV_SITENAME}.${DDEV_TLD}"
volumes:
meili_data:
2 changes: 0 additions & 2 deletions tests/test.bats
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ setup() {

health_checks() {
ddev exec "curl -s meilisearch:7700/health" | grep "available"
# todo: fix later when we understand why this fails in GHA but not on local machine
# ddev exec "curl -s -o /dev/null -I -w '%{http_code}' meilisearch_admin" | grep "200"
}

teardown() {
Expand Down

0 comments on commit d869f95

Please sign in to comment.