geminispace.info

search provider for gemini space
git clone git://git.clttr.info/geminispace.info.git
Log (Feed) | Files | Refs (Tags) | README | LICENSE

README.md (1332B)


      1 # Gemini Universal Search (GUS)
      2 
      3 
      4 ## Dependencies
      5 
      6 1. Install python (>3.5) and [poetry](https://python-poetry.org)
      7 2. Run: `poetry install`
      8 
      9 
     10 ## Making an initial index
     11 
     12 Make sure you have some gemini URLs for testing which are nicely
     13 sandboxed to avoid indexing huge parts of the gemini space.
     14 
     15 1. Create a "seed-requests.txt" file with you test gemini URLs
     16 2. Run: `poetry run crawl -d`
     17 3. Run: `poetry run build_index -d`
     18 
     19 Now you'll have created `index.new` directory, rename it to `index`.
     20 
     21 
     22 ## Running the frontend
     23 
     24 1. Run: `poetry run serve`
     25 2. Navigate your gemini client to: "gemini://localhost/"
     26 
     27 ### Running the frontend in production with systemd
     28 
     29 1. update `infra/gus.service` to match your needs (directory, user)
     30 2. copy `infra/gus.service` to `/etc/systemd/system/`
     31 3. run `systemctl enable gus` and `systemctl start gus`
     32 
     33 ## Running the crawl to update the index
     34 
     35 1. Run: `poetry run crawl`
     36 2. Run: `poetry run build_index`
     37 3. Restart frontend
     38 
     39 ### Running the crawl & indexer in production with systemd
     40 
     41 1. update `infra/gus-crawl.service` & `infra/gus-index.service` to match your needs (directory, user)
     42 2. copy both files to `/etc/systemd/system/`
     43 3. set up a cron job for root with the following params: `0 9 */3 * * systemctl start gus-crawl --no-block` 
     44 
     45 ## Running the test suite
     46 
     47 Run: `poetry run pytest`