From e0a4744abb30c05b3ef7fdf63fd4c1dc9af4b433 Mon Sep 17 00:00:00 2001 From: Aaron Collier Date: Fri, 18 Feb 2022 13:45:34 +0100 Subject: [PATCH 1/4] :memo: Add shortcode for legacy regions and update available images --- docs/data/registry.json | 68 ++++++++++++++++++- .../shortcodes/image-versions-legacy.html | 16 +++++ .../configuration/services/elasticsearch.md | 5 +- .../configuration/services/headless-chrome.md | 2 + docs/src/configuration/services/influxdb.md | 2 + docs/src/configuration/services/kafka.md | 2 + docs/src/configuration/services/memcached.md | 4 +- .../configuration/services/mysql/_index.md | 2 + .../configuration/services/network-storage.md | 2 + docs/src/configuration/services/opensearch.md | 2 + docs/src/configuration/services/postgresql.md | 2 + docs/src/configuration/services/rabbitmq.md | 2 + docs/src/configuration/services/redis.md | 2 + docs/src/configuration/services/solr.md | 2 + docs/src/configuration/services/varnish.md | 2 + docs/src/configuration/services/vault.md | 2 + docs/src/languages/dotnet.md | 2 + docs/src/languages/elixir.md | 2 + docs/src/languages/go.md | 2 + docs/src/languages/java/_index.md | 2 + docs/src/languages/lisp.md | 2 + docs/src/languages/nodejs/_index.md | 2 + docs/src/languages/php/_index.md | 1 + docs/src/languages/python.md | 2 + docs/src/languages/ruby.md | 2 + docs/templates/language-reference.md | 3 + docs/templates/service-reference.md | 3 + 27 files changed, 134 insertions(+), 6 deletions(-) create mode 100644 docs/layouts/shortcodes/image-versions-legacy.html diff --git a/docs/data/registry.json b/docs/data/registry.json index 95ee546621..19a4b089ec 100644 --- a/docs/data/registry.json +++ b/docs/data/registry.json @@ -23,6 +23,14 @@ "84", "86", "91" + ], + "legacy": [ + "73", + "80", + "81", + "83", + "84", + "86" ] } }, @@ -67,6 +75,12 @@ "2.2", "3.1", "5.0" + ], + "legacy": [ + "2.0", + "2.1", + "2.2", + "3.1" ] } }, @@ -179,6 +193,12 @@ "versions": { "deprecated": [], "supported": [ + "1.9", + "1.10", + "1.11", + "1.12" + ], + "legacy": [ "1.9", "1.10" ] @@ -314,7 +334,17 @@ "2.2", "2.3", "2.4", - "2.5" + "2.5", + "2.6", + "2.7" + ], + "legacy": [ + "2.1", + "2.2", + "2.3", + "2.4", + "2.5", + "2.6" ] } }, @@ -347,7 +377,9 @@ "versions": { "deprecated": [], "supported": [ - "1.5" + "1.5", + "2.0", + "2.1" ] } }, @@ -503,6 +535,10 @@ "versions": { "deprecated": [], "supported": [ + "1.0", + "2.0" + ], + "legacy": [ "1.0" ] }, @@ -576,7 +612,11 @@ "versions": { "deprecated": [], "supported": [ + "1.1", "1.2" + ], + "legacy": [ + "1.1" ] }, "versions-dedicated": { @@ -779,6 +819,13 @@ "versions": { "deprecated": [], "supported": [ + "3.5", + "3.6", + "3.7", + "3.8", + "3.9" + ], + "legacy": [ "3.5", "3.6", "3.7", @@ -823,6 +870,12 @@ "5.0", "6.0", "6.2" + ], + "legacy": [ + "3.2", + "4.0", + "5.0", + "6.0" ] }, "versions-dedicated": { @@ -891,6 +944,13 @@ "2.6", "2.7", "3.0" + ], + "legacy": [ + "2.3", + "2.4", + "2.5", + "2.6", + "2.7" ] } }, @@ -981,6 +1041,10 @@ "versions": { "deprecated": [], "supported": [ + "1.6", + "1.8" + ], + "legacy": [ "1.6" ] }, diff --git a/docs/layouts/shortcodes/image-versions-legacy.html b/docs/layouts/shortcodes/image-versions-legacy.html new file mode 100644 index 0000000000..e560487d17 --- /dev/null +++ b/docs/layouts/shortcodes/image-versions-legacy.html @@ -0,0 +1,16 @@ +{{ $image := .Get 0 }} + +{{ with (index .Site.Data.registry $image "versions" ) }} + {{ if index . "legacy" }} + {{ with (index . "legacy" | symdiff (index . "supported")) }} + +

The following versions aren't available in the EU-1 and US-1 regions:

+ +

Consider region migration if your project is in those regions.

+ {{ end }} + {{ end }} +{{ end }} diff --git a/docs/src/configuration/services/elasticsearch.md b/docs/src/configuration/services/elasticsearch.md index 9fda6672ed..1a39d433a3 100644 --- a/docs/src/configuration/services/elasticsearch.md +++ b/docs/src/configuration/services/elasticsearch.md @@ -29,6 +29,8 @@ To update the versions in this table, use docs/data/registry.json |----------------------------------|---------------|---------------| | {{< image-versions image="elasticsearch" status="supported" environment="grid" >}} | {{< image-versions image="elasticsearch" status="supported" environment="dedicated" >}} | {{< image-versions image="elasticsearch" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "elasticsearch" >}} + Due to a licensing change, Elasticsearch versions after 7.10 aren't supported. For newer versions, use [OpenSearch](./opensearch.md) instead. To switch to OpenSearch, follow the same procedure as for [upgrading](#upgrading). @@ -39,9 +41,6 @@ To switch to OpenSearch, follow the same procedure as for [upgrading](#upgrading |----------------------------------|---------------|---------------| | {{< image-versions image="elasticsearch" status="deprecated" environment="grid" >}} | {{< image-versions image="elasticsearch" status="deprecated" environment="dedicated" >}} | {{< image-versions image="elasticsearch" status="deprecated" environment="dedicated-gen-3" >}} | -Elasticsearch 7.9 isn't available in the EU-1 and US-1 regions. -Consider [region migration](../../guides/general/region-migration.md) if your project is in those regions. - ## Relationship The format exposed in the `$PLATFORM_RELATIONSHIPS` [environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/headless-chrome.md b/docs/src/configuration/services/headless-chrome.md index 3be88ff8e8..d93a76215a 100644 --- a/docs/src/configuration/services/headless-chrome.md +++ b/docs/src/configuration/services/headless-chrome.md @@ -17,6 +17,8 @@ Puppeteer can be used to generate PDFs and screenshots of web pages, automate fo |----------------------------------|---------------|---------------| | {{< image-versions image="chrome-headless" status="supported" environment="grid" >}} | {{< image-versions image="chrome-headless" status="supported" environment="dedicated" >}} | {{< image-versions image="chrome-headless" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "chrome-headless" >}} + ## Relationship The format exposed in the `$PLATFORM_RELATIONSHIPS` [environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/influxdb.md b/docs/src/configuration/services/influxdb.md index c6aa450309..3c8109d9e7 100644 --- a/docs/src/configuration/services/influxdb.md +++ b/docs/src/configuration/services/influxdb.md @@ -16,6 +16,8 @@ It exposes an HTTP API for client interaction. See the [InfluxDB documentation]( |----------------------------------|---------------|---------------| | {{< image-versions image="influxdb" status="supported" environment="grid" >}} | {{< image-versions image="influxdb" status="supported" environment="dedicated" >}} | {{< image-versions image="influxdb" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "influxdb" >}} + ## Relationship The format exposed in the ``$PLATFORM_RELATIONSHIPS`` [environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/kafka.md b/docs/src/configuration/services/kafka.md index f2e776ec38..7cd21fb973 100644 --- a/docs/src/configuration/services/kafka.md +++ b/docs/src/configuration/services/kafka.md @@ -16,6 +16,8 @@ It is a framework for storing, reading and analyzing streaming data. See the [Ka |----------------------------------|---------------|---------------| | {{< image-versions image="kafka" status="supported" environment="grid" >}} | {{< image-versions image="kafka" status="supported" environment="dedicated" >}} | {{< image-versions image="kafka" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "kafka" >}} + ## Relationship The format exposed in the ``$PLATFORM_RELATIONSHIPS`` [environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/memcached.md b/docs/src/configuration/services/memcached.md index 30e0c8d884..6b8e8dcaa1 100644 --- a/docs/src/configuration/services/memcached.md +++ b/docs/src/configuration/services/memcached.md @@ -22,7 +22,9 @@ Both Memcached and Redis can be used for application caching. As a general rule, | **Grid** | **Dedicated** | **Dedicated Generation 3** | |----------------------------------|---------------|---------------| -| {{< image-versions image="memcached" status="supported" environment="grid" >}} | {{< image-versions image="redis" status="memcached" environment="dedicated" >}} | {{< image-versions image="redis" status="memcached" environment="dedicated-gen-3" >}} | +| {{< image-versions image="memcached" status="supported" environment="grid" >}} | {{< image-versions image="memcached" status="supported" environment="dedicated" >}} | {{< image-versions image="memcached" status="supported" environment="dedicated-gen-3" >}} | + +{{< image-versions-legacy "memcached" >}} ## Relationship diff --git a/docs/src/configuration/services/mysql/_index.md b/docs/src/configuration/services/mysql/_index.md index 49d29b42d6..c86c4336a3 100644 --- a/docs/src/configuration/services/mysql/_index.md +++ b/docs/src/configuration/services/mysql/_index.md @@ -30,6 +30,8 @@ MySQL and MariaDB have the same behavior and the rest of this page applies to bo |---------------|-------------|--------------------| | {{< image-versions image="mariadb" status="supported" >}} | {{< image-versions image="mysql" status="supported" >}} | {{< image-versions image="oracle-mysql" status="supported" >}} | +{{< image-versions-legacy "mysql" >}} + ### Supported versions on Dedicated environments On Dedicated and Dedicated Generation 3 environments, only MariaDB is available with Galera for replication: diff --git a/docs/src/configuration/services/network-storage.md b/docs/src/configuration/services/network-storage.md index 912d7b4b92..c5fa01ba29 100644 --- a/docs/src/configuration/services/network-storage.md +++ b/docs/src/configuration/services/network-storage.md @@ -13,6 +13,8 @@ The network storage service enables a new kind of `mount` that refers to a share |----------------------------------|---------------|---------------| | {{< image-versions image="network-storage" status="supported" environment="grid" >}} | {{< image-versions image="network-storage" status="supported" environment="dedicated" >}} | {{< image-versions image="network-storage" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "network-storage" >}} + This service is a reference to a version of our network storage implementation, not to a version of a 3rd party application. `network-storage` 2.0 will *not* work on the Grid. We recommend using version 1.0 unless you are a [Dedicated Generation 3](dedicated-gen-3/overview.md) user. {{< note theme="warning">}} diff --git a/docs/src/configuration/services/opensearch.md b/docs/src/configuration/services/opensearch.md index d8e7f5724c..a0b2801f81 100644 --- a/docs/src/configuration/services/opensearch.md +++ b/docs/src/configuration/services/opensearch.md @@ -21,6 +21,8 @@ To update the versions in this table, use docs/data/registry.json |----------------------------------|---------------|---------------| | {{< image-versions image="opensearch" status="supported" environment="grid" >}} | {{< image-versions image="opensearch" status="supported" environment="dedicated" >}} | {{< image-versions image="opensearch" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "opensearch" >}} + ## Relationship The format exposed in the [`$PLATFORM_RELATIONSHIPS` environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/postgresql.md b/docs/src/configuration/services/postgresql.md index 3b92bcfc60..3866c2c599 100644 --- a/docs/src/configuration/services/postgresql.md +++ b/docs/src/configuration/services/postgresql.md @@ -22,6 +22,8 @@ See the [PostgreSQL documentation](https://www.postgresql.org/docs/9.6/index.htm |----------------------------------|---------------|---------------| | {{< image-versions image="postgresql" status="supported" environment="grid" >}} | {{< image-versions image="postgresql" status="supported" environment="dedicated" >}} | {{< image-versions image="postgresql" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "postgresql" >}} + \* No High-Availability on Dedicated. {{< note >}} diff --git a/docs/src/configuration/services/rabbitmq.md b/docs/src/configuration/services/rabbitmq.md index 2c90838c9b..0c47dec1cd 100644 --- a/docs/src/configuration/services/rabbitmq.md +++ b/docs/src/configuration/services/rabbitmq.md @@ -20,6 +20,8 @@ See the [RabbitMQ documentation](http://www.rabbitmq.com/documentation.html) for |----------------------------------|---------------|---------------| | {{< image-versions image="rabbitmq" status="supported" environment="grid" >}} | {{< image-versions image="rabbitmq" status="supported" environment="dedicated" >}} | {{< image-versions image="rabbitmq" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "rabbitmq" >}} + ## Relationship The format exposed in the `$PLATFORM_RELATIONSHIPS` [environment variable](../../development/variables/use-variables.md#use-platformsh-provided-variables): diff --git a/docs/src/configuration/services/redis.md b/docs/src/configuration/services/redis.md index 4d2f4171e7..9ff85d9b19 100644 --- a/docs/src/configuration/services/redis.md +++ b/docs/src/configuration/services/redis.md @@ -28,6 +28,8 @@ Platform.sh supports two different Redis configurations: One persistent (useful |----------------------------------|---------------|---------------| | {{< image-versions image="redis" status="supported" environment="grid" >}} | {{< image-versions image="redis" status="supported" environment="dedicated" >}} | {{< image-versions image="redis" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "redis" >}} + {{% deprecated-versions %}} | **Grid** | **Dedicated** | **Dedicated Generation 3** | diff --git a/docs/src/configuration/services/solr.md b/docs/src/configuration/services/solr.md index 5782920a8a..d32dd13ad4 100644 --- a/docs/src/configuration/services/solr.md +++ b/docs/src/configuration/services/solr.md @@ -23,6 +23,8 @@ Solr search with generic schemas provided, and a custom schema is also supported |----------------------------------|---------------|---------------| | {{< image-versions image="solr" status="supported" environment="grid" >}} | {{< image-versions image="solr" status="supported" environment="dedicated" >}} | {{< image-versions image="solr" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "solr" >}} + {{% deprecated-versions %}} | **Grid** | **Dedicated** | **Dedicated Generation 3** | diff --git a/docs/src/configuration/services/varnish.md b/docs/src/configuration/services/varnish.md index 4b902206ab..e63cc02ccc 100644 --- a/docs/src/configuration/services/varnish.md +++ b/docs/src/configuration/services/varnish.md @@ -14,6 +14,8 @@ However, it is possible to configure a Varnish instance as part of an applicatio |----------------------------------|---------------|---------------| | {{< image-versions image="varnish" status="supported" environment="grid" >}} | {{< image-versions image="varnish" status="supported" environment="dedicated" >}} | {{< image-versions image="varnish" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "varnish" >}} + ## How it works All incoming requests still go through the environment's router first. When using Varnish, a Varnish service sits between the router and the application server or servers. diff --git a/docs/src/configuration/services/vault.md b/docs/src/configuration/services/vault.md index 3ca1bef003..a8cad6a5eb 100644 --- a/docs/src/configuration/services/vault.md +++ b/docs/src/configuration/services/vault.md @@ -12,6 +12,8 @@ The Vault key management service (KMS) provides key management and access contro |----------------------------------|---------------|---------------| | {{< image-versions image="vault-kms" status="supported" environment="grid" >}} | {{< image-versions image="vault-kms" status="supported" environment="dedicated" >}} | {{< image-versions image="vault-kms" status="supported" environment="dedicated-gen-3" >}} | +{{< image-versions-legacy "vault-kms" >}} + ## Add Vault ### Add the service diff --git a/docs/src/languages/dotnet.md b/docs/src/languages/dotnet.md index 508cd91efa..f05b36d446 100644 --- a/docs/src/languages/dotnet.md +++ b/docs/src/languages/dotnet.md @@ -12,6 +12,8 @@ description: | |----------------------------------|---------------| | {{< image-versions image="dotnet" status="supported" environment="grid" >}} | {{< image-versions image="dotnet" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "dotnet" >}} + To specify a .NET Core container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). {{< readFile file="src/registry/images/examples/full/dotnet.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} diff --git a/docs/src/languages/elixir.md b/docs/src/languages/elixir.md index 52826cd1b7..aa4fa9d622 100644 --- a/docs/src/languages/elixir.md +++ b/docs/src/languages/elixir.md @@ -11,6 +11,8 @@ description: Platform.sh supports building and deploying applications written in |----------------------------------|---------------| | {{< image-versions image="elixir" status="supported" environment="grid" >}} | {{< image-versions image="elixir" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "elixir" >}} + To specify an Elixir container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). {{< readFile file="src/registry/images/examples/full/elixir.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} diff --git a/docs/src/languages/go.md b/docs/src/languages/go.md index ac66d30054..2c82481880 100644 --- a/docs/src/languages/go.md +++ b/docs/src/languages/go.md @@ -11,6 +11,8 @@ description: Platform.sh supports building and deploying applications written in |----------------------------------|---------------| | {{< image-versions image="golang" status="supported" environment="grid" >}} | {{< image-versions image="golang" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "golang" >}} + To specify a Go container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). {{< readFile file="src/registry/images/examples/full/golang.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} diff --git a/docs/src/languages/java/_index.md b/docs/src/languages/java/_index.md index 429e8bfc29..2ced165917 100644 --- a/docs/src/languages/java/_index.md +++ b/docs/src/languages/java/_index.md @@ -14,6 +14,8 @@ layout: single |----------------------------------|---------------| | {{< image-versions image="java" status="supported" environment="grid" >}} | {{< image-versions image="java" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "java" >}} + To specify a Java container, use the `type` property in your [app configuration](../../configuration/app/app-reference.md). {{< readFile file="src/registry/images/examples/full/java.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} diff --git a/docs/src/languages/lisp.md b/docs/src/languages/lisp.md index 6b0906a698..a745877b47 100644 --- a/docs/src/languages/lisp.md +++ b/docs/src/languages/lisp.md @@ -11,6 +11,8 @@ description: Platform.sh supports building and deploying applications written in |----------------------------------|---------------| | {{< image-versions image="lisp" status="supported" environment="grid" >}} | {{< image-versions image="lisp" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "lisp" >}} + To specify a Lisp container, use the `type` property in your `.platform.app.yaml`. {{< readFile file="src/registry/images/examples/full/lisp.app.yaml" highlight="yaml">}} diff --git a/docs/src/languages/nodejs/_index.md b/docs/src/languages/nodejs/_index.md index b3e8b9ff90..1c4b86705d 100644 --- a/docs/src/languages/nodejs/_index.md +++ b/docs/src/languages/nodejs/_index.md @@ -13,6 +13,8 @@ layout: single |----------------------------------|---------------| | {{< image-versions image="nodejs" status="supported" environment="grid" >}} | {{< image-versions image="nodejs" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "nodejs" >}} + To use a specific version in a container with a different language, [use a version manager](node-version.md). {{% deprecated-versions %}} diff --git a/docs/src/languages/php/_index.md b/docs/src/languages/php/_index.md index 4689edbce5..68e834307b 100644 --- a/docs/src/languages/php/_index.md +++ b/docs/src/languages/php/_index.md @@ -10,6 +10,7 @@ layout: single |----------------------------------|---------------| | {{< image-versions image="php" status="supported" environment="grid" >}} | {{< image-versions image="php" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "php" >}} Note that from PHP 7.1, the images use the Zend Thread Safe (ZTS) version of PHP. diff --git a/docs/src/languages/python.md b/docs/src/languages/python.md index 57e69a7daa..ce9040bef4 100644 --- a/docs/src/languages/python.md +++ b/docs/src/languages/python.md @@ -11,6 +11,8 @@ description: Platform.sh supports deploying Python applications. Your applicatio |----------------------------------|---------------| | {{< image-versions image="python" status="supported" environment="grid" >}} | {{< image-versions image="python" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "python" >}} + ## Support libraries While it is possible to read the environment directly from your application, it is generally easier and more robust to use the [`platformshconfig`](https://github.com/platformsh/config-reader-python) pip library which handles decoding of service credential information for you. diff --git a/docs/src/languages/ruby.md b/docs/src/languages/ruby.md index eb2636cd87..93ca58b015 100644 --- a/docs/src/languages/ruby.md +++ b/docs/src/languages/ruby.md @@ -14,6 +14,8 @@ description: | |----------------------------------|---------------| | {{< image-versions image="ruby" status="supported" environment="grid" >}} | {{< image-versions image="ruby" status="supported" environment="dedicated" >}} | +{{< image-versions-legacy "ruby" >}} + ## Unicorn based Rails configuration This example uses Unicorn to run a Ruby application. diff --git a/docs/templates/language-reference.md b/docs/templates/language-reference.md index 043bf5b406..73356520b3 100644 --- a/docs/templates/language-reference.md +++ b/docs/templates/language-reference.md @@ -22,6 +22,9 @@ A brief introduction (1--2 sentences) to the language. |----------------------------------|---------------|---------------| | {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | + +{{< image-versions-legacy "" >}} + {{% deprecated-versions %}} diff --git a/docs/templates/service-reference.md b/docs/templates/service-reference.md index 02f86003eb..51fbbfbe62 100644 --- a/docs/templates/service-reference.md +++ b/docs/templates/service-reference.md @@ -22,6 +22,9 @@ A brief introduction (1--2 sentences) to what this service is used for. |----------------------------------|---------------|---------------| | {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | + +{{< image-versions-legacy "" >}} + {{% deprecated-versions %}} From c73c869801ce473869176a9b2c5b181f3d8be157 Mon Sep 17 00:00:00 2001 From: Aaron Collier Date: Fri, 18 Feb 2022 14:10:41 +0100 Subject: [PATCH 2/4] :recycle: Add shortcode for language specification --- docs/layouts/shortcodes/language-specification.md | 13 +++++++++++++ docs/src/languages/dotnet.md | 4 +--- docs/src/languages/elixir.md | 4 +--- docs/src/languages/go.md | 4 +--- docs/src/languages/java/_index.md | 4 +--- docs/src/languages/lisp.md | 4 +--- docs/src/languages/nodejs/_index.md | 2 ++ docs/src/languages/php/_index.md | 4 +--- docs/src/languages/python.md | 2 ++ docs/src/languages/ruby.md | 2 ++ docs/templates/language-reference.md | 13 ++++++++----- 11 files changed, 33 insertions(+), 23 deletions(-) create mode 100644 docs/layouts/shortcodes/language-specification.md diff --git a/docs/layouts/shortcodes/language-specification.md b/docs/layouts/shortcodes/language-specification.md new file mode 100644 index 0000000000..d51bb78ecc --- /dev/null +++ b/docs/layouts/shortcodes/language-specification.md @@ -0,0 +1,13 @@ +{{ $type := .Get "type" }} +### Specify the language + +To use {{ .Get "display_name" }}, specify `{{ $type }}` as your [app's `type`](/configuration/app/app-reference.html#type): + + +
.platform.app.yaml
+{{ highlight ( printf "type: '%s:'" $type ) "yaml" "" }} + +For example: + +
.platform.app.yaml
+{{ highlight ( readFile (printf "src/registry/images/examples/full/%s.app.yaml" $type ) ) "yaml" "" }} diff --git a/docs/src/languages/dotnet.md b/docs/src/languages/dotnet.md index f05b36d446..baf7df394e 100644 --- a/docs/src/languages/dotnet.md +++ b/docs/src/languages/dotnet.md @@ -14,9 +14,7 @@ description: | {{< image-versions-legacy "dotnet" >}} -To specify a .NET Core container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). - -{{< readFile file="src/registry/images/examples/full/dotnet.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} +{{% language-specification type="dotnet" display_name=".Net Core" %}} ## Building the application diff --git a/docs/src/languages/elixir.md b/docs/src/languages/elixir.md index aa4fa9d622..d746a93a04 100644 --- a/docs/src/languages/elixir.md +++ b/docs/src/languages/elixir.md @@ -13,9 +13,7 @@ description: Platform.sh supports building and deploying applications written in {{< image-versions-legacy "elixir" >}} -To specify an Elixir container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). - -{{< readFile file="src/registry/images/examples/full/elixir.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} +{{% language-specification type="elixir" display_name="Elixir" %}} ## Platform.sh variables diff --git a/docs/src/languages/go.md b/docs/src/languages/go.md index 2c82481880..acccd7103f 100644 --- a/docs/src/languages/go.md +++ b/docs/src/languages/go.md @@ -13,9 +13,7 @@ description: Platform.sh supports building and deploying applications written in {{< image-versions-legacy "golang" >}} -To specify a Go container, use the `type` property in your [app configuration](../configuration/app/app-reference.md). - -{{< readFile file="src/registry/images/examples/full/golang.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} +{{% language-specification type="golang" display_name="Go" %}} {{% deprecated-versions %}} diff --git a/docs/src/languages/java/_index.md b/docs/src/languages/java/_index.md index 2ced165917..a99967ec94 100644 --- a/docs/src/languages/java/_index.md +++ b/docs/src/languages/java/_index.md @@ -16,9 +16,7 @@ layout: single {{< image-versions-legacy "java" >}} -To specify a Java container, use the `type` property in your [app configuration](../../configuration/app/app-reference.md). - -{{< readFile file="src/registry/images/examples/full/java.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} +{{% language-specification type="java" display_name="Java" %}} ## Support libraries diff --git a/docs/src/languages/lisp.md b/docs/src/languages/lisp.md index a745877b47..d5fc75ac7e 100644 --- a/docs/src/languages/lisp.md +++ b/docs/src/languages/lisp.md @@ -13,9 +13,7 @@ description: Platform.sh supports building and deploying applications written in {{< image-versions-legacy "lisp" >}} -To specify a Lisp container, use the `type` property in your `.platform.app.yaml`. - -{{< readFile file="src/registry/images/examples/full/lisp.app.yaml" highlight="yaml">}} +{{% language-specification type="lisp" display_name="Lisp" %}} ## Assumptions diff --git a/docs/src/languages/nodejs/_index.md b/docs/src/languages/nodejs/_index.md index 1c4b86705d..7d565aa58d 100644 --- a/docs/src/languages/nodejs/_index.md +++ b/docs/src/languages/nodejs/_index.md @@ -15,6 +15,8 @@ layout: single {{< image-versions-legacy "nodejs" >}} +{{% language-specification type="nodejs" display_name="Node.js" %}} + To use a specific version in a container with a different language, [use a version manager](node-version.md). {{% deprecated-versions %}} diff --git a/docs/src/languages/php/_index.md b/docs/src/languages/php/_index.md index 68e834307b..a5572ffad0 100644 --- a/docs/src/languages/php/_index.md +++ b/docs/src/languages/php/_index.md @@ -14,9 +14,7 @@ layout: single Note that from PHP 7.1, the images use the Zend Thread Safe (ZTS) version of PHP. -To specify a PHP container, use the `type` property in your [app configuration](../../configuration/app/app-reference.md). - -{{< readFile file="src/registry/images/examples/full/php.app.yaml" highlight="yaml" location=".platform.app.yaml" >}} +{{% language-specification type="php" display_name="PHP" %}} {{% deprecated-versions %}} diff --git a/docs/src/languages/python.md b/docs/src/languages/python.md index ce9040bef4..46c46f7cea 100644 --- a/docs/src/languages/python.md +++ b/docs/src/languages/python.md @@ -13,6 +13,8 @@ description: Platform.sh supports deploying Python applications. Your applicatio {{< image-versions-legacy "python" >}} +{{% language-specification type="python" display_name="Python" %}} + ## Support libraries While it is possible to read the environment directly from your application, it is generally easier and more robust to use the [`platformshconfig`](https://github.com/platformsh/config-reader-python) pip library which handles decoding of service credential information for you. diff --git a/docs/src/languages/ruby.md b/docs/src/languages/ruby.md index 93ca58b015..6767c4969c 100644 --- a/docs/src/languages/ruby.md +++ b/docs/src/languages/ruby.md @@ -16,6 +16,8 @@ description: | {{< image-versions-legacy "ruby" >}} +{{% language-specification type="ruby" display_name="Ruby" %}} + ## Unicorn based Rails configuration This example uses Unicorn to run a Ruby application. diff --git a/docs/templates/language-reference.md b/docs/templates/language-reference.md index 73356520b3..d70c670a3c 100644 --- a/docs/templates/language-reference.md +++ b/docs/templates/language-reference.md @@ -11,7 +11,8 @@ How to use 1. Copy this template into /src/docs/languages/. 2. Rename it to match the title. 3. Replace the following content with your own. - 4. Replace all instances of "" in the examples with the language's name. + 4. Replace all instances of "" in the examples with the language's code name (such as "nodejs"). + 5. Replace all instances of "" in the examples with the language's name (such as "Node.js"). --> A brief introduction (1--2 sentences) to the language. @@ -20,17 +21,19 @@ A brief introduction (1--2 sentences) to the language. | **Grid** | **Dedicated** | **Dedicated Generation 3** | |----------------------------------|---------------|---------------| -| {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | +| {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | -{{< image-versions-legacy "" >}} +{{< image-versions-legacy "" >}} + +{{% language-specification type="" display_name="" %}} {{% deprecated-versions %}} | **Grid** | **Dedicated** | **Dedicated Generation 3** | |----------------------------------|---------------|---------------| -| {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | +| {{< image-versions image="" status="supported" environment="grid" >}} | {{< image-versions image="" status="supported" environment="dedicated" >}} | {{< image-versions image="" status="supported" environment="dedicated-gen-3" >}} | ## Usage example @@ -60,4 +63,4 @@ Split each function A description of what templates are. -{{< repolist lang="" >}} +{{< repolist lang="" >}} From 3d41ffba46734c818766eaf7aaf67e6a3aa60d44 Mon Sep 17 00:00:00 2001 From: Aaron Collier Date: Fri, 18 Feb 2022 17:32:24 +0100 Subject: [PATCH 3/4] :memo: Clarify network storage versions --- docs/data/registry.json | 4 ---- docs/src/configuration/services/network-storage.md | 5 ++++- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/data/registry.json b/docs/data/registry.json index 19a4b089ec..b9bebbb72d 100644 --- a/docs/data/registry.json +++ b/docs/data/registry.json @@ -535,10 +535,6 @@ "versions": { "deprecated": [], "supported": [ - "1.0", - "2.0" - ], - "legacy": [ "1.0" ] }, diff --git a/docs/src/configuration/services/network-storage.md b/docs/src/configuration/services/network-storage.md index c5fa01ba29..7dd79cef89 100644 --- a/docs/src/configuration/services/network-storage.md +++ b/docs/src/configuration/services/network-storage.md @@ -15,7 +15,10 @@ The network storage service enables a new kind of `mount` that refers to a share {{< image-versions-legacy "network-storage" >}} -This service is a reference to a version of our network storage implementation, not to a version of a 3rd party application. `network-storage` 2.0 will *not* work on the Grid. We recommend using version 1.0 unless you are a [Dedicated Generation 3](dedicated-gen-3/overview.md) user. +This service is the Platform.sh network storage implementation, not to a version of a third-party application. +Version 2.0 isn't recommended for the Grid. +You should use version 1.0 unless you are a [Dedicated Generation 3](../../dedicated-gen-3/overview.md) user. +Dedicated Generation 3 users can use version 2.0 even on their Development environments. {{< note theme="warning">}} It is not possible to upgrade or downgrade the network storage service version while keeping existing data in place. Changing the service version will require the service to be reinitialized. Any change to the service version will result in existing data becoming inaccessible. From 31c84e2e85abfc5a5b85a75211719800d9ad5d1d Mon Sep 17 00:00:00 2001 From: Aaron Collier Date: Fri, 18 Feb 2022 17:45:47 +0100 Subject: [PATCH 4/4] :bug: Put text back in empty image version cells --- docs/layouts/shortcodes/image-versions.html | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/layouts/shortcodes/image-versions.html b/docs/layouts/shortcodes/image-versions.html index 0047b44c8d..73a79ca7f2 100644 --- a/docs/layouts/shortcodes/image-versions.html +++ b/docs/layouts/shortcodes/image-versions.html @@ -23,8 +23,15 @@ {{ else }} {{ if and (eq $envParam "dedicated-gen-3") (eq $status "supported") }} Working on it! - {{ else }} - None available + {{ if ne $status "deprecated"}} + None available + {{ end }} {{ end }} {{ end }} +{{ else }} + {{ if and (eq $envParam "dedicated-gen-3") (eq $status "supported") }} + Working on it! + {{ else }} + None available + {{ end }} {{ end }}