mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 09:22:43 +03:00
docs: update db getting started guides
https://github.com/hasura/graphql-engine-mono/pull/1904 Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com> GitOrigin-RevId: 4725d1511a53c912fd173d2a6455076d1fcc31c7
This commit is contained in:
parent
ac10c32381
commit
d55777058a
@ -5,7 +5,7 @@
|
||||
.. _api_security:
|
||||
|
||||
API Security
|
||||
====================
|
||||
============
|
||||
|
||||
.. contents:: Table of contents
|
||||
:backlinks: none
|
||||
@ -21,7 +21,7 @@ All API security related features can be found under the ``Security`` tab in the
|
||||
:alt: Security
|
||||
|
||||
Features
|
||||
-------
|
||||
--------
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
|
@ -12,8 +12,61 @@ Getting started with BigQuery
|
||||
:depth: 2
|
||||
:local:
|
||||
|
||||
Run Hasura GraphQL engine
|
||||
-------------------------
|
||||
|
||||
Using Hasura Cloud
|
||||
^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Navigate to `cloud.hasura.io
|
||||
<https://cloud.hasura.io/signup/?pg=docs&plcmt=body&cta=navigate-to-cloud-hasura-io&tech=default>`__, and
|
||||
create a new Hasura Cloud account.
|
||||
|
||||
Once you create a project on Hasura Cloud, hit the "Launch Console" button
|
||||
to open the Hasura Console for your project.
|
||||
|
||||
.. thumbnail:: /img/graphql/cloud/getting-started/create-project.png
|
||||
:alt: Connect new or existing database
|
||||
:width: 556px
|
||||
|
||||
Using docker
|
||||
^^^^^^^^^^^^
|
||||
Get the Hasura docker-compose file:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
# in a new directory run
|
||||
wget https://raw.githubusercontent.com/hasura/graphql-engine/stable/install-manifests/docker-compose/docker-compose.yaml
|
||||
# or run
|
||||
curl https://raw.githubusercontent.com/hasura/graphql-engine/stable/install-manifests/docker-compose/docker-compose.yaml -o docker-compose.yaml
|
||||
|
||||
The following command will run Hasura along with a Postgres database required
|
||||
for its functioning.
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ docker-compose up -d
|
||||
|
||||
Check if the containers are running:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ docker ps
|
||||
|
||||
CONTAINER ID IMAGE ... CREATED STATUS PORTS ...
|
||||
097f58433a2b hasura/graphql-engine ... 1m ago Up 1m 8080->8080/tcp ...
|
||||
b0b1aac0508d postgres ... 1m ago Up 1m 5432/tcp ...
|
||||
|
||||
Please do note that you will see a Postgres database running, which is used by Hasura to store its configuration (Hasura metadata).
|
||||
|
||||
Head to ``http://localhost:8080/console`` to open the Hasura console.
|
||||
|
||||
|
||||
Connecting to a BigQuery project
|
||||
--------------------------------
|
||||
|
||||
Pre-requisites
|
||||
--------------
|
||||
^^^^^^^^^^^^^^
|
||||
|
||||
Hasura GraphQL engine requires the following to connect to a BigQuery project:
|
||||
|
||||
@ -22,7 +75,7 @@ Hasura GraphQL engine requires the following to connect to a BigQuery project:
|
||||
- A `Service Account <https://cloud.google.com/iam/docs/service-accounts>`__ to query the project.
|
||||
|
||||
Creating a Service Account
|
||||
--------------------------
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
- In Google Cloud's console, head to your BigQuery project.
|
||||
|
||||
@ -41,10 +94,13 @@ Creating a Service Account
|
||||
|
||||
- Click on the created service account, ``Keys > ADD KEY > Create New Key > JSON > Create``. This will download a service account file on your computer.
|
||||
|
||||
Connecting to a BigQuery project
|
||||
--------------------------------
|
||||
Connect BigQuery to Hasura
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
- Run Graphql engine with an environment variable set to the contents of the service account. This maybe done as follows if you are using docker:
|
||||
- Update Graphql engine with an environment variable set to the contents of the service account.
|
||||
|
||||
|
||||
For example, this maybe done as follows if you are using docker:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
|
@ -28,7 +28,7 @@ To try Hasura with BigQuery, you'll need your own new or existing BigQuery datab
|
||||
|
||||
Here is how you can get started with Hasura:
|
||||
|
||||
:ref:`Getting Started with BigQuery<database_bigquery_getting_started>`
|
||||
:ref:`Getting Started with BigQuery <database_bigquery_getting_started>`
|
||||
|
||||
.. TODO: DB COMPATIBILITY
|
||||
|
||||
|
@ -18,6 +18,10 @@ Try it out
|
||||
Step 1: Create an account on Hasura Cloud and create a new Hasura Project
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Navigate to `cloud.hasura.io
|
||||
<https://cloud.hasura.io/signup/?pg=docs&plcmt=body&cta=navigate-to-cloud-hasura-io&tech=default>`__, and
|
||||
create a new Hasura Cloud account.
|
||||
|
||||
Once you create a project on Hasura Cloud, hit the "Launch Console" button
|
||||
to open the Hasura Console for your project.
|
||||
|
||||
@ -25,7 +29,6 @@ to open the Hasura Console for your project.
|
||||
:alt: Connect new or existing database
|
||||
:width: 600px
|
||||
|
||||
|
||||
Step 2: Add your Citus database as a source to Hasura
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
|
@ -18,6 +18,10 @@ Try it out
|
||||
Step 1: Create an account on Hasura Cloud and create a new Hasura Project
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Navigate to `cloud.hasura.io
|
||||
<https://cloud.hasura.io/signup/?pg=docs&plcmt=body&cta=navigate-to-cloud-hasura-io&tech=default>`__, and
|
||||
create a new Hasura Cloud account.
|
||||
|
||||
Once you create a project on Hasura Cloud, hit the "Launch Console" button
|
||||
to open the Hasura Console for your project.
|
||||
|
||||
|
@ -44,6 +44,8 @@ Hasura GraphQL engine supports:
|
||||
|
||||
- :ref:`Postgres <database_postgres>`
|
||||
- :ref:`MS SQL Server <database_ms_sql_server>`
|
||||
- :ref:`Citus - Hyperscale <database_citus-hyperscale-postgres>`
|
||||
- :ref:`BigQuery <database_bigquery>`
|
||||
- **MySQL** (in preview) - See the :ref:`preview guide <mysql_preview>`
|
||||
|
||||
.. admonition:: Additional Resources
|
||||
|
Loading…
Reference in New Issue
Block a user