chore(postgraphile): extend readme.md

This commit is contained in:
dancingCycle 2024-03-11 15:42:12 +01:00
parent 1dfebef976
commit 28cbeee2d8
2 changed files with 33 additions and 1 deletions

View File

@ -22,6 +22,10 @@ const postgraphileOptions = {
};
console.log('database url: ', process.env.DATABASE_URL);
/**
* pass the database URL to PostGraphile for it to bootstrap the application
*/
app.use(postgraphile(process.env.DATABASE_URL, "public", postgraphileOptions));
console.log('port: ', process.env.PORT);

View File

@ -1,5 +1,33 @@
* foo
```
ssh -N -L 5432:localhost:5432 -p 22 zvbn_nvp@83.223.91.130
npm i
node index.js
```
```
* open in browser
```
http://localhost:<port from .env file>/graphiql
```
* test
```
query MyQuery {
allServices {
edges {
node {
routeByRouteId {
shortName
}
routeBundleByRouteBundleId {
longName
}
serviceLevelByServiceLevelId {
longName
shortName
}
}
}
}
}
```