---
title: Deploy
---

# Deploy Ecolyo for development

This section will show you how to deploy your project on different environments.

## Builds branches

3 builds branch are today available for Ecolyo:

- **build**: reflect the build of the master branch and the version deployed in production environment
- **build-test**: reflect a temporary build which can be used for test purpose
- **build-dev**: reflect the build of the dev branch and the version deployed on dev environment

## Deploy to build branches

Make sure that:

- you are on the right branch (dev or master) depending on the environment you need to deploy.
- your branch is up to date
- you node modules are up to date

First build the application :

```sh
yarn build
```

Next you can deploy the build to the target branch:

```sh
# deploy on build-test branch
yarn deploy-test
# deploy on build-dev branch
yarn deploy-dev
# deploy on build branch
yarn deploy
```

## Auto deploy for dev

In order to prevent manual action for deployment, a gitlab-runner has been configured to deploy every changes on the `dev` branch on our [ecolyodemo](https://ecolyo.ecolyodemo.cozy.self-data.alpha.grandlyon.com/) env

:::info cicd scripts
You can find all scripts used in cicd jobs on the following [repository](https://forge.grandlyon.com/web-et-numerique/factory/llle_project/ecolyo-infra-scripts)
:::

## Deploy build-test branch to a Scaleway instance for testing

You can directly use the content of build-test branch to update one instance for test purpose.
Simply use the dedicated script `update_ecolyo_test.sh <instance_name>` with the targeted instance (from the server).
By default we use the ecolyodemo instance for testing intermediate functionality.

## Deploy build-dev branch to all Scaleway instances

You can directly use the content of build-dev branch to update apps on dev environment using scripts (from the server).
Simply use the dedicated script `update_all_ecolyo_dev.sh`.

For more information you can check for [Easy Cozy scripts](/docs/easycozy/commands.md).