From 6dee6ba48536ff4cf6069f1d6b2ed68aab5fd035 Mon Sep 17 00:00:00 2001 From: Tristan Bastian Date: Wed, 13 Mar 2024 20:10:42 +0100 Subject: [PATCH] add support for using this action on a GitHub Enterprise instance Signed-off-by: Tristan Bastian --- action.yml | 4 ++++ entrypoint.sh | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 9ecb56d..81fea48 100644 --- a/action.yml +++ b/action.yml @@ -49,6 +49,10 @@ inputs: description: 'Use a custom URL instead of *.github.io' required: false default: '' + github_server_url: + description: 'GitHub server URL' + required: true + default: ${{ github.server_url }} runs: using: 'docker' image: 'Dockerfile' \ No newline at end of file diff --git a/entrypoint.sh b/entrypoint.sh index b0421cf..8d86324 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -48,7 +48,7 @@ echo " executor.json echo "\"url\":\"${GITHUB_PAGES_WEBSITE_URL}\"," >> executor.json # ??? echo "\"reportUrl\":\"${GITHUB_PAGES_WEBSITE_URL}/${INPUT_GITHUB_RUN_NUM}/\"," >> executor.json -echo "\"buildUrl\":\"https://github.com/${INPUT_GITHUB_REPO}/actions/runs/${INPUT_GITHUB_RUN_ID}\"," >> executor.json +echo "\"buildUrl\":\"${INPUT_GITHUB_SERVER_URL}/${INPUT_GITHUB_REPO}/actions/runs/${INPUT_GITHUB_RUN_ID}\"," >> executor.json echo "\"buildName\":\"GitHub Actions Run #${INPUT_GITHUB_RUN_ID}\",\"buildOrder\":\"${INPUT_GITHUB_RUN_NUM}\"}" >> executor.json #cat executor.json mv ./executor.json ./${INPUT_ALLURE_RESULTS}