Staging environment

How to create a staging environment with Qovery

Very often, before merging new changes to your production environment, you'd like to test them live in a deployed environment that resembles your production. Doing so allows you to make sure that everything works as expected before releasing new changes to your clients. Achieving it with Qovery is very simple and works well even if your project is made out of many applications, e.g. multiple backend services, websites, databases and so on.

Creating a staging environment

  1. Create a new environment

    Staging Environment

  2. Add your applications

    Choose your application names, git repositories, and branches you want to use for staging. You can set up the same environment as you use for production or use the clone functionality.

    Staging Environment

    Staging Environment

    As you can see in the screenshots, we used staging branches for our applications in the staging environment. Applications in this environment will be deployed using source code from staging branches.

  3. Add required services/databases

    If your project requires databases, you can add them to your staging environment.

    Staging Environment

  4. Set up secrets and environment variables

    The last step you probably need to take is to set up another set of secrets and environment variables that are separate from your production. You can do it in your application Environment Variables section:

    Staging Environment

    Now, before merging new code to production, you can merge it first to your staging branch (or any other branch name you use for this purpose). New changes will be reflected in your staging environment, which is separate from your production.

    After making sure new changes work well, all you need to do to release them to your clients is to update your production branch with the commits you tested in your staging environment.