diff --git a/docs/action-properties-secrets.md b/docs/action-properties-secrets.md index 02aa2a96..c142166d 100644 --- a/docs/action-properties-secrets.md +++ b/docs/action-properties-secrets.md @@ -171,7 +171,7 @@ URL of an Embed Service that takes the appended URL and returns an embeddable HT The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1" +"https://helix-pages.anywhere.run/helix-services/embed@v1" ``` ## DATA_EMBED_SERVICE @@ -197,7 +197,7 @@ URL of a DataEmbed Service that takes the appended URL and returns an iterable J The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v1" +"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v2" ``` ## EMBED_SELECTOR diff --git a/docs/secrets-properties-data_embed_service.md b/docs/secrets-properties-data_embed_service.md index 8b0e865a..79966463 100644 --- a/docs/secrets-properties-data_embed_service.md +++ b/docs/secrets-properties-data_embed_service.md @@ -19,5 +19,5 @@ URL of a DataEmbed Service that takes the appended URL and returns an iterable J The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v1" +"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v2" ``` diff --git a/docs/secrets-properties-embed_service.md b/docs/secrets-properties-embed_service.md index c637b44f..cfc4c0dc 100644 --- a/docs/secrets-properties-embed_service.md +++ b/docs/secrets-properties-embed_service.md @@ -19,5 +19,5 @@ URL of an Embed Service that takes the appended URL and returns an embeddable HT The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1" +"https://helix-pages.anywhere.run/helix-services/embed@v1" ``` diff --git a/docs/secrets.md b/docs/secrets.md index e9a0323d..e1c7da2b 100644 --- a/docs/secrets.md +++ b/docs/secrets.md @@ -171,7 +171,7 @@ URL of an Embed Service that takes the appended URL and returns an embeddable HT The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1" +"https://helix-pages.anywhere.run/helix-services/embed@v1" ``` ## DATA_EMBED_SERVICE @@ -197,7 +197,7 @@ URL of a DataEmbed Service that takes the appended URL and returns an iterable J The default value is: ```json -"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v1" +"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v2" ``` ## EMBED_SELECTOR diff --git a/docs/secrets.schema.json b/docs/secrets.schema.json index bda810fc..9d17e4a3 100644 --- a/docs/secrets.schema.json +++ b/docs/secrets.schema.json @@ -1 +1 @@ -{"meta:license":["Copyright 2018 Adobe. All rights reserved.","This file is licensed to you under the Apache License, Version 2.0 (the \"License\");","you may not use this file except in compliance with the License. You may obtain a copy","of the License at http://www.apache.org/licenses/LICENSE-2.0","","Unless required by applicable law or agreed to in writing, software distributed under","the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS","OF ANY KIND, either express or implied. See the License for the specific language","governing permissions and limitations under the License."],"$id":"https://ns.adobe.com/helix/pipeline/secrets","$schema":"http://json-schema.org/draft-07/schema#","title":"Secrets","type":"object","meta:status":"stable","additionalProperties":false,"description":"Secrets passed into the pipeline such as API Keys or configuration settings.","patternProperties":{"[A-Z0-9_]+":{"type":["boolean","integer","number","string"]}},"properties":{"REPO_RAW_ROOT":{"type":"string","format":"uri","description":"The Base URL for retrieving raw text files from GitHub","default":"https://raw.githubusercontent.com/"},"REPO_API_ROOT":{"type":"string","format":"uri","description":"The base URL for all GitHub API operations","default":"https://api.github.com/"},"EMBED_ALLOWLIST":{"type":"string","description":"Comma-separated list of allowed hostnames for embeds. Supports `*.example.com` as a subdomain wildcard. Use `*` to allow all embeds (potentially insecure and conflicting with `DATA_EMBED_ALLOWLIST`)","default":"www.youtube.com, unsplash.com, soundcloud.com, lottiefiles.com, www.slideshare.net, vimeo.com, www.instagram.com, twitter.com, open.spotify.com, web.spotify.com, player.vimeo.com, www.linkedin.com, w.soundcloud.com, www.slideshare.net, youtu.be, media.giphy.com, video.tv.adobe.com, api.soundcloud.com, xd.adobe.com"},"DATA_EMBED_ALLOWLIST":{"type":"string","description":"Comma-separated list of allowed hostnames for data embeds. Supports `*.example.com` as a subdomain wildcard. Use `*` to allow all embeds (potentially insecure and conflicting with `EMBED_ALLOWLIST`)","default":"docs.google.com, *.sharepoint.com"},"EMBED_SERVICE":{"type":"string","description":"URL of an Embed Service that takes the appended URL and returns an embeddable HTML representation.","default":"https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1"},"DATA_EMBED_SERVICE":{"type":"string","description":"URL of a DataEmbed Service that takes the appended URL and returns an iterable JSON representation.","default":"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v1"},"EMBED_SELECTOR":{"type":"string","description":"Selector to be used when resolving internal embeds.","default":"embed"},"IMAGES_MIN_SIZE":{"type":"integer","description":"Minimum physical width of responsive images to generate","default":480},"HTTP_TIMEOUT":{"type":"integer","description":"Timeout for outgoing HTTP requests in milliseconds","default":1000},"HTTP_TIMEOUT_EXTERNAL":{"type":"integer","description":"Timeout for outgoing HTTP requests to external services in milliseconds","default":20000},"TEST_BOOLEAN":{"type":"boolean","default":true},"XML_PRETTY":{"type":"boolean","description":"Print XML with line breaks and indentation","default":true},"SANITIZE_DOM":{"type":"boolean","description":"Sanitize the HTML output to guard against XSS attacks. \n\n**Note:** this flag applies a pretty aggressive DOM filtering that will strip out a lot of HTML that your authors might find useful. The setting is meant for processing truly untrusted inputs, such as comments in a social media site.","default":false},"RESOLVE_GITREF_SERVICE":{"type":"string","description":"API endpoint or action name to the service that resolves github refs to commit SHAs.","default":""},"GITHUB_TOKEN":{"type":"string","description":"GitHub access token to use while fetching markdown. See https://help.github.com/en/articles/creating-a-personal-access-token-for-the-command-line.","default":""},"CONTENT_PROXY_URL":{"type":"string","format":"uri","description":"URL of the content proxy service."}}} +{"meta:license":["Copyright 2018 Adobe. All rights reserved.","This file is licensed to you under the Apache License, Version 2.0 (the \"License\");","you may not use this file except in compliance with the License. You may obtain a copy","of the License at http://www.apache.org/licenses/LICENSE-2.0","","Unless required by applicable law or agreed to in writing, software distributed under","the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS","OF ANY KIND, either express or implied. See the License for the specific language","governing permissions and limitations under the License."],"$id":"https://ns.adobe.com/helix/pipeline/secrets","$schema":"http://json-schema.org/draft-07/schema#","title":"Secrets","type":"object","meta:status":"stable","additionalProperties":false,"description":"Secrets passed into the pipeline such as API Keys or configuration settings.","patternProperties":{"[A-Z0-9_]+":{"type":["boolean","integer","number","string"]}},"properties":{"REPO_RAW_ROOT":{"type":"string","format":"uri","description":"The Base URL for retrieving raw text files from GitHub","default":"https://raw.githubusercontent.com/"},"REPO_API_ROOT":{"type":"string","format":"uri","description":"The base URL for all GitHub API operations","default":"https://api.github.com/"},"EMBED_ALLOWLIST":{"type":"string","description":"Comma-separated list of allowed hostnames for embeds. Supports `*.example.com` as a subdomain wildcard. Use `*` to allow all embeds (potentially insecure and conflicting with `DATA_EMBED_ALLOWLIST`)","default":"www.youtube.com, unsplash.com, soundcloud.com, lottiefiles.com, www.slideshare.net, vimeo.com, www.instagram.com, twitter.com, open.spotify.com, web.spotify.com, player.vimeo.com, www.linkedin.com, w.soundcloud.com, www.slideshare.net, youtu.be, media.giphy.com, video.tv.adobe.com, api.soundcloud.com, xd.adobe.com"},"DATA_EMBED_ALLOWLIST":{"type":"string","description":"Comma-separated list of allowed hostnames for data embeds. Supports `*.example.com` as a subdomain wildcard. Use `*` to allow all embeds (potentially insecure and conflicting with `EMBED_ALLOWLIST`)","default":"docs.google.com, *.sharepoint.com"},"EMBED_SERVICE":{"type":"string","description":"URL of an Embed Service that takes the appended URL and returns an embeddable HTML representation.","default":"https://helix-pages.anywhere.run/helix-services/embed@v1"},"DATA_EMBED_SERVICE":{"type":"string","description":"URL of a DataEmbed Service that takes the appended URL and returns an iterable JSON representation.","default":"https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v2"},"EMBED_SELECTOR":{"type":"string","description":"Selector to be used when resolving internal embeds.","default":"embed"},"IMAGES_MIN_SIZE":{"type":"integer","description":"Minimum physical width of responsive images to generate","default":480},"HTTP_TIMEOUT":{"type":"integer","description":"Timeout for outgoing HTTP requests in milliseconds","default":1000},"HTTP_TIMEOUT_EXTERNAL":{"type":"integer","description":"Timeout for outgoing HTTP requests to external services in milliseconds","default":20000},"TEST_BOOLEAN":{"type":"boolean","default":true},"XML_PRETTY":{"type":"boolean","description":"Print XML with line breaks and indentation","default":true},"SANITIZE_DOM":{"type":"boolean","description":"Sanitize the HTML output to guard against XSS attacks. \n\n**Note:** this flag applies a pretty aggressive DOM filtering that will strip out a lot of HTML that your authors might find useful. The setting is meant for processing truly untrusted inputs, such as comments in a social media site.","default":false},"RESOLVE_GITREF_SERVICE":{"type":"string","description":"API endpoint or action name to the service that resolves github refs to commit SHAs.","default":""},"GITHUB_TOKEN":{"type":"string","description":"GitHub access token to use while fetching markdown. See https://help.github.com/en/articles/creating-a-personal-access-token-for-the-command-line.","default":""},"CONTENT_PROXY_URL":{"type":"string","format":"uri","description":"URL of the content proxy service."}}} diff --git a/src/schemas/secrets.schema.json b/src/schemas/secrets.schema.json index 55e628ae..43ffde86 100644 --- a/src/schemas/secrets.schema.json +++ b/src/schemas/secrets.schema.json @@ -48,12 +48,12 @@ "EMBED_SERVICE": { "type": "string", "description": "URL of an Embed Service that takes the appended URL and returns an embeddable HTML representation.", - "default": "https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1" + "default": "https://helix-pages.anywhere.run/helix-services/embed@v1" }, "DATA_EMBED_SERVICE": { "type": "string", "description": "URL of a DataEmbed Service that takes the appended URL and returns an iterable JSON representation.", - "default": "https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v1" + "default": "https://adobeioruntime.net/api/v1/web/helix/helix-services/data-embed@v2" }, "EMBED_SELECTOR": { "type": "string", diff --git a/test/fixtures/embeds.html b/test/fixtures/embeds.html index bcc442b7..6261e798 100644 --- a/test/fixtures/embeds.html +++ b/test/fixtures/embeds.html @@ -3,7 +3,7 @@

Hello “World”

Gatsby-Style-Embeds

+ src="https://helix-pages.anywhere.run/helix-services/embed@v1/https://www.youtube.com/embed/2Xc9gXyf2G4"> video: https://www.youtube.com/embed/2Xc9gXyf2G4

@@ -12,7 +12,7 @@

Gatsby-Style-Embeds

video: http foo bar looks interesting, but doesn’t work either.

+ src="https://helix-pages.anywhere.run/helix-services/embed@v1/https://www.youtube.com/watch?v=KOxbO0EI4MA">

Link + Image-Style Embeds Audi R8is just an image.

Image-Style Embeds

+ src="https://helix-pages.anywhere.run/helix-services/embed@v1/https://www.youtube.com/watch?v=KOxbO0EI4MA">

@@ -37,7 +37,7 @@

Image-Style Embeds

is on a paragraph of its own.

IA Writer-Style Embeds

+ src="https://helix-pages.anywhere.run/helix-services/embed@v1/https://www.youtube.com/watch?v=KOxbO0EI4MA">

https://www.youtube.com/watch?v=KOxbO0EI4MA

diff --git a/test/testDataEmbeds.js b/test/testDataEmbeds.js index caff6c83..3a707b76 100644 --- a/test/testDataEmbeds.js +++ b/test/testDataEmbeds.js @@ -547,7 +547,7 @@ describe('Integration Test with Data Embeds (version locked)', () => { action.versionLock = new VersionLock({ __ow_headers: { - 'x-ow-version-lock': 'data-embed=data-embed@v1.2.3', + 'x-ow-version-lock': 'data-embed=v1.2.3', }, }); action.downloader = new Downloader(context, action, { forceHttp1: true }); diff --git a/test/testEmbedHandler.js b/test/testEmbedHandler.js index 49b1b37a..47c3a352 100644 --- a/test/testEmbedHandler.js +++ b/test/testEmbedHandler.js @@ -86,7 +86,7 @@ describe('Test Embed Handler', () => { await coerce(action); embed(action.secrets)((_, tagname, parameters, children) => { - assert.equal(parameters.src, 'https://adobeioruntime.net/api/v1/web/helix/helix-services/embed@v1/https://www.example.com/'); + assert.equal(parameters.src, 'https://helix-pages.anywhere.run/helix-services/embed@v1/https://www.example.com/'); assert.equal(children, undefined); assert.equal(tagname, 'esi:include'); }, node); diff --git a/test/testPipeWithMarkupConfig.js b/test/testPipeWithMarkupConfig.js index cf0e3cd3..0f921674 100644 --- a/test/testPipeWithMarkupConfig.js +++ b/test/testPipeWithMarkupConfig.js @@ -240,13 +240,13 @@ https://soundcloud.com/mariamamermounib/el-ghasala?in=mariamamermounib/sets/mari `

from github.

-        
+        
         
           

https://www.youtube.com/watch?v=dQw4w9WgXcQ

And here is something from Soundcloud

- +

https://soundcloud.com/mariamamermounib/el-ghasala?in=mariamamermounib/sets/mariam-amer-mounib-amel-eh-fe

`); });