2018-09-11 14:11:24 +03:00
Updating Hasura GraphQL engine on Heroku
========================================
2018-12-03 15:12:24 +03:00
.. contents :: Table of contents
:backlinks: none
:depth: 1
:local:
2019-09-11 10:17:14 +03:00
This guide will help you update the Hasura GraphQL engine running on Heroku. This guide assumes that you already have a
2018-09-11 14:11:24 +03:00
Hasura GraphQL engine running on Heroku.
The current latest version is:
.. raw :: html
<code>hasura/graphql-engine:<span class="latest-release-tag"> latest</span></code>
Follow these steps to update Hasura GraphQL engine to the lastest version:
2018-12-03 15:12:24 +03:00
Step 1: Clone the Hasura GraphQL engine Heroku app
--------------------------------------------------
2018-09-11 14:11:24 +03:00
The Hasura app with Heroku buildpack/configuration is available at:
2019-09-11 10:17:14 +03:00
https://github.com/hasura/graphql-engine-heroku.
2018-09-11 14:11:24 +03:00
2019-02-06 09:39:36 +03:00
Clone the above repository.
2019-09-11 10:17:14 +03:00
If you already have this, then pull the latest changes which will have the updated GraphQL engine Docker image.
2018-09-11 14:11:24 +03:00
2018-12-03 15:12:24 +03:00
Step 2: Attach your Heroku app
------------------------------
2018-09-11 14:11:24 +03:00
Let's say your Heroku app is called `` hasura-heroku `` and is running on `` https://hasura-heroku.herokuapp.com `` .
2019-02-06 09:39:36 +03:00
2019-07-29 09:24:39 +03:00
Navigate to your project directory, use the `Heroku CLI <https://devcenter.heroku.com/articles/heroku-cli> `_ to configure the git repo you cloned in Step 1
2018-09-11 14:11:24 +03:00
to be able to push to this app.
.. code-block :: bash
2019-02-06 09:39:36 +03:00
# Replace <hasura-heroku> with your Heroku app's name
$ heroku git:remote -a <hasura-heroku>
$ heroku stack:set container -a <hasura-heroku>
2018-09-11 14:11:24 +03:00
2019-07-29 09:24:39 +03:00
You can find your Heroku git repo in your Heroku - Settings - Info - Heroku Git URL
2019-09-11 10:17:14 +03:00
Step 3: **git push** to deploy the latest Hasura GraphQL engine
---------------------------------------------------------------
2018-09-11 14:11:24 +03:00
When you `` git push `` to deploy, the Heroku app will get updated with the latest changes:
.. code-block :: bash
$ git push heroku master
2019-09-11 10:17:14 +03:00
Deploy a specific version of the Hasura GraphQL engine
------------------------------------------------------
2018-09-11 14:11:24 +03:00
2019-09-11 10:17:14 +03:00
Head to the `` Dockerfile `` in the git repo you cloned in step 1.
2018-09-11 14:11:24 +03:00
Change the `` FROM `` line to the specific version you want. A list of all releases can be found
2019-09-11 10:17:14 +03:00
at https://github.com/hasura/graphql-engine/releases.
2018-09-11 14:11:24 +03:00
.. code-block :: Dockerfile
:emphasize-lines: 1
FROM hasura/graphql-engine:v1.0.0-alpha01
...
...
Change `` v1.0.0-alpha01 `` to `` v1.0.0-alpha02 `` for example, and then `` git push heroku master `` to deploy.