Skip to content
Open
8 changes: 4 additions & 4 deletions sites/platform/src/learn/tutorials/migrating.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
---
title: Migrating to {{% vendor/name %}}
description: See how to migrate your app to {{% vendor/name %}} so it's ready to be deployed.
title: Converting to {{% vendor/name %}}
description: See how to convert your app to {{% vendor/name %}} so it's ready to be deployed.
keywords:
- "set remote"
- migration
---

If you already have an app running somewhere else, you want to migrate it to {{% vendor/name %}} and deploy it.
If you already have an app running somewhere else, you want to convert it to {{% vendor/name %}} and deploy it.
To do so, follow these steps.


## Before you begin

You need:
Expand Down
15 changes: 5 additions & 10 deletions sites/platform/src/projects/region-migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,16 +145,11 @@ Once the new project is running and the DNS has fully propagated, delete the old

## Alternative process

**These tools are not directly supported by {{% vendor/name %}} support team, but you can open issues in their respective repositories directly.**

We have open-sourced [ClonSun](https://github.com/upsun/clonsun), a tool that allows you to clone a project from one region to another.
ClonSun helps you migrate most of your project assets from one region to another with some remaining manual steps like moving your domain names from
one region to the other (or at the CDN level) and update your DNS records.

Although not directly supported by {{% vendor/name %}},
an agency named [Contextual Code](https://www.contextualcode.com/) has built a bash migration script.
This script automates most common configurations.
If your site is a typical single app with a single SQL database,
the script should take care of most of the process for you.
ClonSun helps you migrate most of your project assets from one region to another with some remaining manual steps like moving your domain names from one region to the other (or at the CDN level) and update your DNS records.

We also have [ConvSun](https://github.com/upsun/convsun), a tool that allows you to change existing configuration files to another format. It converts details from files like `services.yaml` and `routes.yaml`, and generates a new `config.yaml` file. This streamlines the conversion process by significantly reducing the manual effort required to adapt your app’s infrastructure setup.

Although not directly supported by {{% vendor/name %}}, an agency named [Contextual Code](https://www.contextualcode.com/) has built a bash migration script. This script automates most common configurations. If your site is a typical single app with a single SQL database, the script should take care of most of the process for you.

See more at the [{{% vendor/name %}} Project Migration repository](https://gitlab.com/contextualcode/platformsh-migration).
63 changes: 56 additions & 7 deletions sites/upsun/src/learn/tutorials/migrating/from-psh.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,71 @@
---
title: From Platform.sh
description: See how to migrate your app to {{% vendor/name %}} so it's ready to be deployed.
title: Converting a project
description: See how to configure your app to {{% vendor/name %}} so it's ready to be deployed.
keywords:
- "set remote"
---

If you already have an app running somewhere else, you want to migrate it to {{% vendor/name %}} and deploy it.
To do so, follow these steps.
There are two ways to change the configuration files of your projects to make them {{% vendor/name %}} compatible.

1. [Convert projects with the CLI](#convert-with-the-cli)
2. [Convert projects manually](#convert-manually)

## Before you begin

You need:

- An app that works and is ready to be built
- Code in Git
- A Platform.sh application that works and is ready to be built
- The code in Git
- A {{< vendor/name >}} account -- if you don't already have one, [register](https://upsun.com/register/).
- The [{{< vendor/name >}} CLI](/administration/cli/_index.md) installed locally

## Convert with the CLI

To assist with converting applications from Platform.sh to {{% vendor/name %}}, the convsun tool is available as part of the {{% vendor/name %}} CLI. This feature automates the conversion of Platform.sh config files into a format required by {{% vendor/name %}}, significantly reducing manual effort.

Check failure on line 24 in sites/upsun/src/learn/tutorials/migrating/from-psh.md

View workflow job for this annotation

GitHub Actions / vale

[vale] sites/upsun/src/learn/tutorials/migrating/from-psh.md#L24

[Vale.Spelling] Did you really mean 'convsun'?
Raw output
{"message": "[Vale.Spelling] Did you really mean 'convsun'?", "location": {"path": "sites/upsun/src/learn/tutorials/migrating/from-psh.md", "range": {"start": {"line": 24, "column": 85}}}, "severity": "ERROR"}

### Key functions
The convsun tool performs the following transformations:

Check failure on line 27 in sites/upsun/src/learn/tutorials/migrating/from-psh.md

View workflow job for this annotation

GitHub Actions / vale

[vale] sites/upsun/src/learn/tutorials/migrating/from-psh.md#L27

[Vale.Spelling] Did you really mean 'convsun'?
Raw output
{"message": "[Vale.Spelling] Did you really mean 'convsun'?", "location": {"path": "sites/upsun/src/learn/tutorials/migrating/from-psh.md", "range": {"start": {"line": 27, "column": 5}}}, "severity": "ERROR"}

1. Generation of Upsun `config.yaml`
- Creates a new `config.yaml` file - the primary configuration file for {{% vendor/name %}} projects.
- Extracts relevant information from `.platform.app.yaml`, `services.yaml`, and `routes.yaml`.

2. Refactoring of obsolete or incompatible fields
Removes resource-related fields that are not applicable in {{% vendor/name %}}. This includes:

- Disk values
- Size settings (e.g., S, M, L)
- Legacy resources blocks
- Any deprecated or unsupported container options in the source configuration

3. Mount and storage adjustments
- Converts mounts of type local into {{% vendor/name %}}'s storage format to support horizontal scaling and infrastructure consistency.
- Ensures that volumes and file persistence are aligned with how {{% vendor/name %}} manages data across containers.

4. Reorganization of custom service configuration
- Moves custom configuration for services such as `Solr` into the `.upsun/ directory`, which is used to hold project-specific overrides and custom assets.

5. Support for cron jobs
- Identifies cron jobs defined in Platform.sh and provides guidance on how to replicate similar functionality in {{% vendor/name %}}.
- Flags any cron schedules requiring special support and prepares the `config.yaml` accordingly.

### Example usage

```bash
uspun project:convert
```
You will be prompted to enter the path to the Platform.sh project you would like to convert.

The Convsun feature then performs the conversion within the {{% vendor/name %}} CLI and outputs the updated `config.yaml` file to the specified destination directory.

Check failure on line 59 in sites/upsun/src/learn/tutorials/migrating/from-psh.md

View workflow job for this annotation

GitHub Actions / vale

[vale] sites/upsun/src/learn/tutorials/migrating/from-psh.md#L59

[Vale.Spelling] Did you really mean 'Convsun'?
Raw output
{"message": "[Vale.Spelling] Did you really mean 'Convsun'?", "location": {"path": "sites/upsun/src/learn/tutorials/migrating/from-psh.md", "range": {"start": {"line": 59, "column": 5}}}, "severity": "ERROR"}

## Convert manually

If you prefer not to use the CLI tool, or if your project has custom requirements that require a more hands-on approach, you can manually update your Platform.sh configuration to be compatible with {{% vendor/name %}}.

Manual conversion gives you full control over the transition process and can be useful for projects with non-standard setups or advanced customizations.

Follow the steps below to begin a manual migration.

## 1. Export from previous system

Start by exporting everything you might need from your current app.
Expand Down Expand Up @@ -198,7 +247,7 @@
```

`instance` mounts on {{% vendor/name %}} are the equivalent of `local` mounts on {{% vendor/psh_ref %}}.
To ensure continuity when migrating from {{% vendor/psh_ref %}} to {{% vendor/name %}},
To ensure continuity when converting from {{% vendor/psh_ref %}} to {{% vendor/name %}},
the `local` mount type works as an alias for the `instance` mount type.

However, it is recommended to change the type of your `local` mounts to `instance` or another [supported mount type](/create-apps/app-reference/single-runtime-image.html#define-a-mount).
Expand Down
11 changes: 11 additions & 0 deletions sites/upsun/src/projects/region-migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,17 @@ Once the new project is running and the DNS has fully propagated, delete the old

## Alternative process

We have open-sourced [ClonSun](https://github.com/upsun/clonsun), a tool that allows you to clone a project from one region to another.
ClonSun helps you migrate most of your project assets from one region to another with some remaining manual steps like moving your domain names from one region to the other (or at the CDN level) and update your DNS records.

We also have [ConvSun](https://github.com/upsun/convsun), a tool that allows you to change existing configuration files to another format. It converts details from files like `services.yaml` and `routes.yaml`, and generates a new `config.yaml` file. This streamlines the conversion process by significantly reducing the manual effort required to adapt your app’s infrastructure setup.

{{< note theme="info" >}}

To learn more about ConvSun and how it works, read the [converting projects](https://docs.upsun.com/learn/tutorials/migrating/from-psh.html) page.

{{< /note >}}

Although not directly supported by {{% vendor/name %}},
an agency named [Contextual Code](https://www.contextualcode.com/) has built a bash migration script.
This script automates most common configurations.
Expand Down
Loading