This is the API repo for https://github.ist. You may also want to take a look to Web and Fetcher
Before the installation, please provide the seed data via Fetcher. You can find the instructions in the fetcher repo.
- Install dependencies with
./mix deps.get
- Create and migrate your database with
./mix ecto.create && ./mix ecto.migrate
- Seed the database with
./mix run priv/repo/seeds.exs
To run commands other than mix tasks, you can use the ./run
script.
./run iex -S mix
- Change directory to src with
cd src/
- Install dependencies with
mix deps.get
- Create and migrate your database with
mix ecto.create && mix ecto.migrate
- Seed the database with
mix run priv/repo/seeds.exs
You can start the API with mix phx.server
command. You can visit http://0.0.0.0:4000
from your browser.
You can start the API with docker-compose up
. You can check it via curl 'http://localhost:4000/graphql' -H 'content-type: application/json' --data-binary '{"operationName":null,"variables":{"username":"mdegis"},"query":"query ($username: String!) {\n developer(username: $username) {\n ...BasicDeveloper\n bio\n githubUrl\n __typename\n }\n}\n\nfragment BasicDeveloper on Developer {\n id\n name\n username\n avatarUrl\n __typename\n}\n"}'