Skip to content

Commit

Permalink
Merge pull request #2672 from github/mbg/start-proxy/include-type-in-…
Browse files Browse the repository at this point in the history
…urls-output
  • Loading branch information
mbg authored Jan 8, 2025
2 parents 3407610 + b25558b commit fb65b6c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
5 changes: 4 additions & 1 deletion lib/start-proxy-action.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/start-proxy-action.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion src/start-proxy-action.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,10 @@ async function startProxy(

const registry_urls = config.all_credentials
.filter((credential) => credential.url !== undefined)
.map((credential) => credential.url);
.map((credential) => ({
type: credential.type,
url: credential.url,
}));
core.setOutput("proxy_urls", JSON.stringify(registry_urls));
} catch (error) {
core.setFailed(`start-proxy action failed: ${util.getErrorMessage(error)}`);
Expand Down
2 changes: 1 addition & 1 deletion start-proxy/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ outputs:
proxy_ca_certificate:
description: The proxy's internal CA certificate in PEM format
proxy_urls:
description: The URLs of the configured registries, as a JSON array.
description: A stringified JSON array of objects containing the types and URLs of the configured registries.
runs:
using: node20
main: "../lib/start-proxy-action.js"
Expand Down

0 comments on commit fb65b6c

Please sign in to comment.