• Here is how to enable the Advanced search (https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/elasticsearch.md).

    it should be as easy as these three steps:

    1. Run gdk config set elasticsearch.enabled true
    2. Run gdk reconfigure.
    3. Go to admin settings and enable it in the UI don't forget to click the index the instance button

    After you are successful. Your settings should look like this:

    Screenshot_2025-03-26_at_11.23.59

    Your search page will look like this (notice the Code scope and Advanced Search above the search input field):

    Screenshot_2025-03-26_at_11.26.00

    This step is a bit more involved (https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/zoekt.md#configure-zoekt-in-development).

    two steps to enable:

    1. Run gdk config set zoekt.enabled true.
    2. Run gdk reconfigure.
    3. Run this in your terminal:
    echo 'ApplicationSetting.current.update!(zoekt_settings: { zoekt_indexing_enabled: true, zoekt_indexing_paused: false, zoekt_search_enabled: true, zoekt_cpu_to_tasks_ratio: 1.0 })
    zoekt_node = ::Search::Zoekt::Node.online.last
    namespace = Namespace.find_by_full_path("flightjs") # Some namespace you want to enable
    enabled_namespace = Search::Zoekt::EnabledNamespace.find_or_create_by(namespace: namespace)
    zoekt_node.indices.find_or_create_by!(zoekt_enabled_namespace_id: enabled_namespace.id, namespace_id: namespace.id, zoekt_replica_id: Search::Zoekt::Replica.for_enabled_namespace!(enabled_namespace).id)' | rails c

    This step might take a minute or two to process. You can check on the namespace indexing status using this:

    echo 'Search::Zoekt::Index.all' | rails c

    After you enable Exact code search you should also see this:

    Screenshot_2025-03-26_at_11.24.14

    Your search will look like this (notice the Exact code search above the search input field):

    Screenshot_2025-03-26_at_11.32.28

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment