Skip to content

Commit 83569ee

Browse files
authored
Merge pull request #29 from iLem0n/master
Enable GHE
2 parents 12f5926 + 3baf78a commit 83569ee

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Inputs:
1919
* `app_version` Explicitly specify app version in package. If not defined then used chart values.
2020
* `chart_version` Explicitly specify chart version in package. If not defined then used chart values.
2121
* `index_dir` The location of `index.yaml` file in the repo, defaults to the same value as `target_dir`
22+
* `enterprise_url` The URL of enterprise github server in the format `<server-url>/<organisation>`
2223

2324
## Examples
2425

action.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ inputs:
4949
index_dir:
5050
description: "The location of `index.yaml` file in the repo, defaults to the same value as `target_dir`"
5151
required: false
52+
enterprise_url:
53+
description: "The URL of enterprise github server in the format '<server-url>/<organisation>'"
54+
required: false
5255
runs:
5356
using: 'docker'
5457
image: 'Dockerfile'
@@ -67,3 +70,4 @@ runs:
6770
- ${{ inputs.app_version }}
6871
- ${{ inputs.chart_version }}
6972
- ${{ inputs.index_dir }}
73+
- ${{ inputs.enterprise_url }}

src/entrypoint.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ COMMIT_EMAIL=${11}
3131
APP_VERSION=${12}
3232
CHART_VERSION=${13}
3333
INDEX_DIR=${14}
34+
ENTERPRISE_URL=${15}
3435

3536
CHARTS=()
3637
CHARTS_TMP_DIR=$(mktemp -d)
@@ -71,7 +72,11 @@ main() {
7172
fi
7273

7374
if [[ -z "$REPO_URL" ]]; then
74-
REPO_URL="https://x-access-token:${GITHUB_TOKEN}@github.com/${OWNER}/${REPOSITORY}"
75+
if [[ -z "$ENTERPRISE_URL" ]]; then
76+
REPO_URL="https://x-access-token:${GITHUB_TOKEN}@github.com/${OWNER}/${REPOSITORY}"
77+
else
78+
REPO_URL="https://x-access-token:${GITHUB_TOKEN}@${ENTERPRISE_URL}/${REPOSITORY}"
79+
fi
7580
fi
7681

7782
if [[ -z "$COMMIT_USERNAME" ]]; then

0 commit comments

Comments
 (0)