https://github.com/seven-33/museum-search
Multi-container web application that searches museum names and locations using React + GraphQL + Elasticsearch
https://github.com/seven-33/museum-search
apollo-server docker nodejs react react-apollo-graphql tailwindcss typescript
Last synced: 3 months ago
JSON representation
Multi-container web application that searches museum names and locations using React + GraphQL + Elasticsearch
- Host: GitHub
- URL: https://github.com/seven-33/museum-search
- Owner: Seven-33
- License: mit
- Created: 2023-03-30T13:47:59.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2023-03-30T13:48:43.000Z (about 2 years ago)
- Last Synced: 2025-01-08T12:20:53.897Z (4 months ago)
- Topics: apollo-server, docker, nodejs, react, react-apollo-graphql, tailwindcss, typescript
- Language: TypeScript
- Homepage:
- Size: 1.2 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# museum-search
[](https://travis-ci.org/PoffM/museum-search)
[](https://codeclimate.com/github/PoffM/museum-search/test_coverage)
[](https://codeclimate.com/github/PoffM/museum-search/maintainability)Multi-container application providing a UI and GraphQL API to search museum names and locations.
* Filter the search results in the list and map UI using a keyword search.
* Zoom in on the map to get museum counts by more precise areas and see labeled pins on the map for
individual museums.* Hover over a museum item on the list to highlight that museum on the map. Click on the list item to zoom the map to that museum.

## Stack
This application runs on a multi-container stack including:
* Front-end: My TypeScript/React application with a list+map UI using [react-apollo](https://github.com/apollographql/react-apollo) to query the back-end.
* Back-end: My TypeScript/Node.js application using [apollo-server](https://github.com/apollographql/apollo-server) to provide a GraphQL API for searching museums.
* ElasticSearch: A third-party search engine I use to search+filter museums by keyword and geospatial criteria.## Continuous Integration / Continuous Delivery
This repo uses Travis for continuous integration and continuous delivery.
On every commit and pull request, Travis runs the test suite, and reports success/failure and test
coverage. It sends the test reports to CodeClimate, which provides code quality analysis and test
coverage reports.On every tagged commit to master, Travis builds and pushes the API and client docker images to
Docker Hub with the Git tag as the Docker tag.[API Docker image](https://hub.docker.com/r/poffm/museum-search-server)
[Client Docker image](https://hub.docker.com/r/poffm/museum-search-client)
## To launch:
From this repo's top directory, run:
```bash
docker-compose up
```This will launch the application with no data.
## To add data:
This can be done while the app is running.
1. Get "museums.csv" from https://www.kaggle.com/imls/museum-directory
2. Put museums.csv in the "data" directory at the top of this repo.
3. From this repo's top directory, run:```
docker-compose run -e MUSEUMS_CSV=/data/museums.csv museum-api-migrate
```- Note: The "/data/museums.csv" in this command refers to a path inside the museum-api-migrate container, but the "data" directory in this path is a volume that links to this repo's "data" directory. This is how the museum-api-migrate container can read the csv file that is pasted into this repo's data directory.
## Access the front-end application:
Go to \ in your browser, where \ is the host IP running docker. This could be localhost, or 192.168.99.100 for docker-machine on Windows.
## Access the GraphQL Playground UI:
Go to \:4000 in your browser, where \ is the host IP running docker. This could be localhost, or 192.168.99.100 for docker-machine on Windows.