Code Monkey home page Code Monkey logo

hx-test-stacks's Introduction

How to use this demo

โš ๏ธ Disclaimer: Only tested with Meilisearch, Windows 11 and Docker Desktop.

1. Have a running instance of your search service

Example: Meilisearch running as a separate docker container and available at http://localhost:7700

Remark: All get master API key that setup to MeiliSearch and then request admin API key for setup in step 2. (your-api-key)

2. Modify the searchsync.config.cjs

server: {
    type: 'meilisearch',
    host: 'http://host.docker.internal:7700',   // accessing localhost within a container
    key: '<your-api-key>',
  },
   reindexOnStart: true,                        // Need ""true" for this tutorial
   collections: {
    test_collection: {                          // name of the directus-collection
      fields: ['title', 'description'],         // fields of the directus-collection
    },
  },

3. Run docker-compose.yml with build flag

docker compose -f docker-compose.yml up --build

4. Check - Loaded extensions & notice the warning

step_4_notice_warning

If you see this, you know all is fine. We haven't created the collection yet.

5. Login to Directus with http://localhost:8055

// Initial values from .env

[email protected]
ADMIN_PASSWORD=123qweasd

6. Create collection and fields

step_6_create_collection

7. Create first item

step_7_item

8. Restart Docker Containers

Stop containers:

pressing CTRL+C (Windows) to cancel running command

Start containers:

docker compose -f docker-compose.yml up

9. Check - No warning

step_9_check

10. Check - Meilisearch Dashboard at http://localhost:7700

You should find the collection "test_collection" as an available index. When selected, we should see our item.

step_10_meilisearch

hx-test-stacks's People

Contributors

hx-natthawat avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.