diff --git a/.github/workflows/review-app.yml b/.github/workflows/review-app.yml index 6e644605..65e92e80 100644 --- a/.github/workflows/review-app.yml +++ b/.github/workflows/review-app.yml @@ -20,7 +20,7 @@ jobs: ref: ${{ github.event.pull_request.head.ref }} token: ${{ secrets.GITHUB_TOKEN }} fetch-depth: 0 - - name: Create review app + - name: Manage review app uses: CleverCloud/clever-cloud-review-app@v1.1.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/content/doc/addons/elastic/_index.md b/content/doc/addons/elastic/_index.md index 0a1f5d47..34fc609c 100644 --- a/content/doc/addons/elastic/_index.md +++ b/content/doc/addons/elastic/_index.md @@ -24,7 +24,8 @@ Provisioning the Elastic Stack addon on Clever Cloud will give you an Elasticsea ## Versions -The current versions supported at add-on creation are 7 and 8. +The current versions supported at add-on creation are the following: +{{< software_versions_shared_dedicated elasticsearch>}} ## Elasticsearch diff --git a/content/doc/addons/mongodb/_index.md b/content/doc/addons/mongodb/_index.md index a429035d..f6e7b060 100644 --- a/content/doc/addons/mongodb/_index.md +++ b/content/doc/addons/mongodb/_index.md @@ -18,15 +18,15 @@ aliases: - /doc/deploy/addon/mongodb/managing-mongodb type: docs --- +## Overview MongoDB is an open source NoSQL document-oriented database. We provide these databases with daily backups and monitoring for both shared and dedicated plans. -## Versions +## Supported Versions In order to comply with [MongoDB Server Side Public License](https://www.mongodb.com/licensing/server-side-public-license), the version currently installed by the add-on is: -- on shared plans (DEV) : MongoDB 4.0.3 -- on newly created dedicated databases (plans XS Small Space and above) : MongoDB 4.0.3 +{{< software_versions_shared_dedicated mongo>}} ### Higher Versions diff --git a/content/doc/addons/mysql/_index.md b/content/doc/addons/mysql/_index.md index 88f4a458..5395c0a1 100644 --- a/content/doc/addons/mysql/_index.md +++ b/content/doc/addons/mysql/_index.md @@ -14,15 +14,12 @@ aliases: - /doc/deploy/addon/mysql/mysql type: docs --- - +## Overview MySQL is an open-source relational database management system (RDBMS). -## Versions - -The version currently installed by the add-on is : +## Supported Versions -- on shared plans (DEV) : MySQL 8.0 -- on newly created dedicated databases (plans XS Small Space and above) : MySQL 5.7.20 or 8.0 +{{< software_versions_shared_dedicated mysql>}} {{% content/db-backup %}} diff --git a/content/doc/addons/postgresql/_index.md b/content/doc/addons/postgresql/_index.md index dbaed020..530ed0c9 100644 --- a/content/doc/addons/postgresql/_index.md +++ b/content/doc/addons/postgresql/_index.md @@ -17,14 +17,13 @@ aliases: type: docs --- +## Overview PostgreSQL is an object-relational database management system (ORDBMS) with an emphasis on extensibility and on standards-compliance. -## Versions +## Supported Versions -Versions currently available for order are as follows: -- On shared (DEV) cluster: PostgreSQL version 15 -- On dedicated plans: PostgreSQL versions 10, 11, 12, 13, 14 and 15 +{{< software_versions_shared_dedicated pg>}} {{% content/db-backup %}} diff --git a/content/doc/addons/redis.md b/content/doc/addons/redis.md index 741c0604..6c417926 100644 --- a/content/doc/addons/redis.md +++ b/content/doc/addons/redis.md @@ -20,7 +20,9 @@ Redis is an open source, in-memory data structure store, used as database, cache ## Version -The version currently installed by the add-on is : Redis 7.2.4 +The version currently installed by the add-on are the following : + +{{< software_versions_shared_dedicated elasticsearch>}} {{% content/db-backup %}} diff --git a/content/doc/applications/dotnet/_index.md b/content/doc/applications/dotnet/_index.md index 0c16749b..2a20bbb3 100644 --- a/content/doc/applications/dotnet/_index.md +++ b/content/doc/applications/dotnet/_index.md @@ -37,7 +37,11 @@ You don't need to change a lot in your application, the *requirements* section e ### .NET version -The default version used on Clever Cloud is `8.0`. You can change it by setting the `CC_DOTNET_VERSION` environment variable to `6.0`. Clever Cloud doesn't support non-LTS and older versions. +The versions used on Clever Cloud are the following: + +{{< runtimes_versions dotnet >}} + +You can change the default version by setting the `CC_DOTNET_VERSION` environment variable to `6.0`. Clever Cloud doesn't support non-LTS and older versions. ### Requirements diff --git a/content/doc/applications/elixir/_index.md b/content/doc/applications/elixir/_index.md index 43feabc3..e158ad48 100644 --- a/content/doc/applications/elixir/_index.md +++ b/content/doc/applications/elixir/_index.md @@ -30,7 +30,9 @@ Clever Cloud supports Elixir based applications. ### Mandatory configuration -- Get your Elixir version in your console with `$ elixir -v` and set the environment variable **CC_ELIXIR_VERSION** to its value (available versions as of today are `1.8`, `1.9`, `1.10`, `1.11`, `1.12`, `1.13`, `1.14`, `1.15` or `1.16`). +Get your Elixir version in your console with `$ elixir -v` and set the environment variable `CC_ELIXIR_VERSION` to its value. Available versions as of today are the following: + +{{< runtimes_versions elixir >}} #### Compatibility between Elixir and Erlang/OTP diff --git a/content/doc/applications/java/java-gradle.md b/content/doc/applications/java/java-gradle.md index 610bcc2f..46f95f6d 100644 --- a/content/doc/applications/java/java-gradle.md +++ b/content/doc/applications/java/java-gradle.md @@ -29,6 +29,12 @@ Note : like other runtimes, Java application need listen on `0.0.0.0:8080` {{% content/java-versions %}} +Accepted values are the following: + +{{< runtimes_versions java >}} + +(`graalvm-ce` for GraalVM 21.0.0.2, based on OpenJDK 11.0) + ## Configure your Java application You *must* provide a `clevercloud/gradle.json` file (gradle.json file in diff --git a/content/doc/applications/java/java-jar.md b/content/doc/applications/java/java-jar.md index 1a596916..bb4161c1 100644 --- a/content/doc/applications/java/java-jar.md +++ b/content/doc/applications/java/java-jar.md @@ -26,6 +26,10 @@ Note : like other runtimes, Java application needs to listen on `0.0.0.0:8080` {{% content/java-versions %}} +{{< runtimes_versions java >}} + +(`graalvm-ce` for GraalVM 21.0.0.2, based on OpenJDK 11.0) + ## Configure your Java application You *must* either have the `CC_JAR_PATH` environment variable containing the diff --git a/content/doc/applications/java/java-maven.md b/content/doc/applications/java/java-maven.md index 911d1456..a6878695 100644 --- a/content/doc/applications/java/java-maven.md +++ b/content/doc/applications/java/java-maven.md @@ -45,6 +45,10 @@ Your application must be set to listen on the port 8080. {{% content/java-versions %}} +{{< runtimes_versions java >}} + +(`graalvm-ce` for GraalVM 21.0.0.2, based on OpenJDK 11.0) + ### Mandatory configuration #### Option 1: JSON file in repository diff --git a/content/doc/applications/java/java-war.md b/content/doc/applications/java/java-war.md index 5d8632cb..fad8b712 100644 --- a/content/doc/applications/java/java-war.md +++ b/content/doc/applications/java/java-war.md @@ -46,6 +46,10 @@ The supported containers are listed below: {{% content/java-versions %}} +{{< runtimes_versions java >}} + +(`graalvm-ce` for GraalVM 21.0.0.2, based on OpenJDK 11.0) + ## Configure your Java application {{< callout type="warning" >}} diff --git a/content/doc/applications/javascript/nodejs.md b/content/doc/applications/javascript/nodejs.md index 2b79205c..08f196e5 100644 --- a/content/doc/applications/javascript/nodejs.md +++ b/content/doc/applications/javascript/nodejs.md @@ -38,6 +38,8 @@ Be sure that: You can use the `engines.node` field in `package.json` to define the wanted version, if not provided we will use the latest LTS version available on Clever Cloud. +{{< runtimes_versions node >}} + ### About package.json The `package.json` file should look like the following: diff --git a/content/doc/applications/php/_index.md b/content/doc/applications/php/_index.md index 2d34bb62..3360f4fe 100644 --- a/content/doc/applications/php/_index.md +++ b/content/doc/applications/php/_index.md @@ -20,8 +20,6 @@ aliases: PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML. -PHP is available on our platform with the branches 5.6, 7.2, 7.3, 7.4, 8.0, 8.1, 8.2 and 8.3. You can use FTP or Git to deploy your applications. - The HTTP server is [Apache 2](https://httpd.apache.org/), and the PHP code is executed by [PHP-FPM](https://php-fpm.org/). {{% content/create-application %}} @@ -32,18 +30,11 @@ The HTTP server is [Apache 2](https://httpd.apache.org/), and the PHP code is ex ### Choose your PHP version -Set the `CC_PHP_VERSION` environment variable to one of the following values: +Set the `CC_PHP_VERSION` environment variable to one of the following versions. -- `5.6` -- `7.2` -- `7.3` -- `7.4` -- `8.0` -- `8.1` -- `8.2` -- `8.3` +{{< runtimes_versions PHP >}} -All new PHP applications are created with a default `CC_PHP_VERSION`, set to `8.3`. You can of course change it whenever you want then redeploy your application to use the version you want. We only support values based on the first two digits (`X` or `X.Y`, not `X.Y.Z`). +All new PHP applications are created with a default `CC_PHP_VERSION`. You can of course change it whenever you want then redeploy your application to use the version you want. We only support values based on the first two digits (`X` or `X.Y`, not `X.Y.Z`). The configuration file for your PHP application must be `/clevercloud/php.json`, that is a *php.json* file in a `/clevercloud` folder at the root of your application. diff --git a/content/doc/applications/python/_index.md b/content/doc/applications/python/_index.md index 3f43ec82..84e155a8 100644 --- a/content/doc/applications/python/_index.md +++ b/content/doc/applications/python/_index.md @@ -22,7 +22,9 @@ comments: false Python is a programming language that lets you work more quickly and integrate your systems more efficiently. -Python 2.7, 3.7, 3.8, 3.9, 3.10 and 3.11 are available on Clever Cloud. You can use Git to deploy your application. +### Supported Versions + +{{< runtimes_versions python >}} {{% content/create-application %}} diff --git a/data/runtime_versions.yml b/data/runtime_versions.yml new file mode 100644 index 00000000..0a8eb955 --- /dev/null +++ b/data/runtime_versions.yml @@ -0,0 +1,53 @@ +node: + default: + - "v20.15.0" +PHP: + default: + - "8.3" + accepted: + - "5.6" + - "7.2" + - "7.3" + - "7.4" + - "8.0" + - "8.1" + - "8.2" +python: + default: + - "3.12.4" + accepted: + - "2.7" + - "3.7" + - "3.8" + - "3.9" + - "3.10" + - "3.11" + - "3.12" +dotnet: + default: + - "6.0" + accepted: + - "8.0" +elixir: + default: + - "1.16" + accepted: + - "1.8" + - "1.9" + - "1.10" + - "1.11" + - "1.12" + - "1.13" + - "1.14" + - "1.15" +java: + default: + - "11" + accepted: + - "22" + - "21" + - "17" + - "11" + - "8" + - "7" + - "graalvm-ce" diff --git a/data/software_versions_shared_dedicated.yml b/data/software_versions_shared_dedicated.yml new file mode 100644 index 00000000..787078b8 --- /dev/null +++ b/data/software_versions_shared_dedicated.yml @@ -0,0 +1,36 @@ +# Example usage: +#myDB +# shared: +# - version_1 +# - version_2 +# dedicated: +# - version_1 +# - version_1 +# - version_2 +pg: + dedicated: + - "v11.22" + - "v12.19" + - "v13.15" + - "v14.12" + - "v15.7" + dev: + - "v15" +mysql: + dedicated: + - "v5.7.20" + - "v8.0.36" + dev: + - "v8.0" +mongo: + dedicated: + - "v4.0.3" + dev: + - "v4.0.3" +elasticsearch: + dedicated: + - "v7.17.10" + - "v8.10.2" +redis: + dedicated: + - "v7.2.4" diff --git a/layouts/shortcodes/content/java-versions.md b/layouts/shortcodes/content/java-versions.md index 91766f4f..de51a995 100644 --- a/layouts/shortcodes/content/java-versions.md +++ b/layouts/shortcodes/content/java-versions.md @@ -1,11 +1,6 @@ ## Available Java versions -Simply set the environment variable **CC_JAVA_VERSION** to the version you want. - - -⚠️ Clever Cloud uses Java version 11 by default. New applications have the `CC_JAVA_VERSION` environment variable set to **21**. - -Accepted values are `7`, `8`, `11`, `17`, `21`, `22` or `graalvm-ce` (for GraalVM 21.0.0.2, based on OpenJDK 11.0). +Set the environment variable `CC_JAVA_VERSION` to the version you want. We follow the official Java [roadmap](https://www.oracle.com/java/technologies/java-se-support-roadmap.html) by supporting both LTS and latest non-LTS versions. diff --git a/layouts/shortcodes/runtimes_versions.html b/layouts/shortcodes/runtimes_versions.html new file mode 100644 index 00000000..0c9fb5d1 --- /dev/null +++ b/layouts/shortcodes/runtimes_versions.html @@ -0,0 +1,49 @@ +{{ $software := or (.Get 0) }} +{{ $version_list := .Site.Data.runtime_versions }} + +{{ with index $version_list $software }} + {{ $default := .default | default (slice) }} + {{ $accepted := .accepted | default (slice) }} + {{ $default_len := len $default }} + {{ $accepted_len := len $accepted }} + {{ $max_len := $default_len }} + {{ if gt $accepted_len $default_len }} + {{ $max_len = $accepted_len }} + {{ end }} + + + + + {{ if $default_len }} + + {{ end }} + {{ if $accepted_len }} + + {{ end }} + + + + {{ range $i := seq 0 (sub $max_len 1) }} + + {{ if $default_len }} + + {{ end }} + {{ if $accepted_len }} + + {{ end }} + + {{ end }} + +
Default VersionAccepted Versions
+ {{ with index $default $i }} + {{ . }} + {{ else }} + {{ end }} + + {{ with index $accepted $i }} + {{ . }} + {{ else }} + + {{ end }} +
+{{ end }} diff --git a/layouts/shortcodes/software_versions_shared_dedicated.html b/layouts/shortcodes/software_versions_shared_dedicated.html new file mode 100644 index 00000000..4c20e391 --- /dev/null +++ b/layouts/shortcodes/software_versions_shared_dedicated.html @@ -0,0 +1,38 @@ +{{ $software := or (.Get 0) }} +{{ $version_list := .Site.Data.software_versions_shared_dedicated }} +{{ $software_versions := index $version_list $software }} +{{ $has_dev := false }} + +{{ if $software_versions.dev }} + {{ $has_dev = true }} +{{ end }} + + + + + {{ if $has_dev }} + + {{ end }} + + + + {{ range $index, $dedicated_version := $software_versions.dedicated }} + + + {{ if $has_dev }} + + {{ end }} + + {{ end }} + +
DedicatedDev
{{ $dedicated_version }} + {{ with index $software_versions.dev $index }} + {{ . }} + {{ else }} + + {{ end }} +
+{{ if $has_dev }} + {{ $.Page.RenderString "{{< callout type=\"warning\">}} Important: Dev plans are free and intended solely for testing purposes. They don't provide the same guarantees or SLAs as dedicated plans. {{< /callout >}}" | safeHTML }} +{{ end }} +