• Stars
    star
    140
  • Rank 261,473 (Top 6 %)
  • Language
    Rust
  • License
    GNU General Publi...
  • Created over 5 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Rust / Hasura / GraphQL

Rust + Hasura Rust

This is an example of a Rust server that functions as a remote schema for Hasura.

It demonstrates:

You can learn more about this stack from this talk.

Package Manager

Cargo

Setup

  • Your Hasura schema must have a table user, with a id column of type uuid, and also a username column of type text.
  • Set an ADMIN_SECRET and a JWT_SECRET on the graphql engine, and share these with the Rust server as environment variables.
  • Use graphqurl to generate schema.json
  • gq $HASURA_ENDPOINT -H "x-hasura-admin-secret: $ADMIN_SECRET" --introspect --format json > ./graphql/schema.json

Start

  • cargo run

Environment Variables

Key Example
PORT 8000
HASURA_ENDPOINT http://127.0.0.1:8080/v1/graphql
ADMIN_SECRET foo
JWT_SECRET {"type":"HS256","key":"3QQ6FD+o0+c7tzQQVfjpMkNDi2yARAAKzQQk8O2IKoxQQ4nF7EdAh8s3TwpHwrdQQ6R"}

More Repositories

1

solana-rust-examples

Demonstrating how to use Rust to interact with the Solana blockchain.
Rust
106
star
2

elm-phoenix-example

minimum elm + phoenix setup, with webpack
Elixir
55
star
3

mineral-app

TypeScript
27
star
4

solana-connect

Standalone wallet UI for Solana dApps
Elm
11
star
5

mineral

Move
11
star
6

learn-aws

FAC Workshop - November 2015
JavaScript
10
star
7

pow-dapp

The world's first proof-of-work NFT ๐Ÿ’ฅ
Elm
9
star
8

home

overengineering practice
Elm
7
star
9

alumni

alumni display page for https://foundersandcoders.com/
Elm
6
star
10

elm-webpack

An Elm + Webpack boilerplate with live reload.
Elm
5
star
11

emojifier

text is boring, make it less so
JavaScript
4
star
12

debugging-workshop

FAC Workshop - April 2016
JavaScript
4
star
13

elm-reloader

Live reload Webpack plugin for Elm.
JavaScript
4
star
14

rotools-js

npm package for functional utilities
JavaScript
4
star
15

nodejs-server-examples

Node.js glitches for https://foundersandcoders.com/
4
star
16

ooft

image file size shrinker for front end
JavaScript
3
star
17

sui-zk-wallet

Elm
3
star
18

bash-export

how to use bash to export your vars
3
star
19

helpers

Elm
2
star
20

bonkcinerator

https://bonkcinerator.com/
Elm
2
star
21

pup

deploy purescript using up
PureScript
2
star
22

psst

e2e encrypted chat pwa
Elm
2
star
23

pow-program

Rust
2
star
24

promise-workshop

FAC/GSG Workshop - April 2017
JavaScript
1
star
25

rotools

Rust and stuff
Rust
1
star
26

nugget-frontend

Rapid QR code payments, powered by Solana
Elm
1
star
27

vanilla-elixir-server

Elixir
1
star
28

idiom-generator

aws lambda twitter bot
JavaScript
1
star
29

haskell-ajax

i'm basically an expert now
Haskell
1
star
30

elm-port-gen

Elm
1
star
31

points

Elm
1
star
32

push

JavaScript
1
star
33

vigenere

npm package for basic encoding and decoding
JavaScript
1
star
34

cli-publish

TypeScript
1
star
35

time-locked-balance

Move
1
star