Skip to content

Commit 17441f5

Browse files
committed
fix: fix BACK-635, add hasura
1 parent e1615dc commit 17441f5

File tree

2 files changed

+41
-1
lines changed

2 files changed

+41
-1
lines changed

dockerfiles/README.md

+26-1
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,29 @@ You can view your fake GCS information at: `http://localhost:9184/storage/v1/b/{
4141
"etag": "RVRhZw==",
4242
"locationType": "region"
4343
}
44-
```
44+
```
45+
46+
### Hasura for GraphQL
47+
We use Hasura for GraphQL. Run the following to update the metadata.
48+
```shell
49+
curl -X POST -H 'Content-Type: application/json' \
50+
--data '{
51+
"type": "bulk",
52+
"source": "default",
53+
"resource_version": 1,
54+
"args": [
55+
{
56+
"type": "postgres_track_tables",
57+
"args": {
58+
"allow_warnings": true,
59+
"tables": [
60+
{"table": {"name": "finalize_block_events", "schema": "public"}, "source": "default"},
61+
{"table": {"name": "move_events", "schema": "public"}, "source": "default"},
62+
{"table": {"name": "transaction_events", "schema": "public"}, "source": "default"}
63+
]
64+
}
65+
}
66+
]
67+
}' \
68+
http://localhost:8080/v1/metadata
69+
```

dockerfiles/docker-compose-informative.yml

+15
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,21 @@ services:
1717
timeout: 5s
1818
retries: 5
1919

20+
graphql-engine:
21+
image: hasura/graphql-engine:v2.43.0
22+
ports:
23+
- "8080:8080"
24+
restart: always
25+
environment:
26+
HASURA_GRAPHQL_METADATA_DATABASE_URL: postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/hasura_metadata
27+
HASURA_GRAPHQL_DATABASE_URL: postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB}
28+
HASURA_GRAPHQL_ENABLE_CONSOLE: "true"
29+
HASURA_GRAPHQL_DEV_MODE: "true"
30+
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
31+
depends_on:
32+
postgres:
33+
condition: service_healthy
34+
2035
storage:
2136
container_name: gcs
2237
image: fsouza/fake-gcs-server

0 commit comments

Comments
 (0)