diff --git a/README.md b/README.md
index 51ada32..93eb640 100644
--- a/README.md
+++ b/README.md
@@ -1,16 +1,16 @@
# GitHub Action for GraalVM [](https://github.com/graalvm/setup-graalvm/actions/workflows/test.yml)
-This GitHub action sets up [GraalVM Community Edition][repo] and GraalVM components such as [Native Image][native-image] and [Truffle languages][truffle-languages].
+This GitHub action sets up GraalVM [Community Edition (CE)][repo] or [Enterprise Edition (EE)][graalvm-ee] as well as GraalVM components such as [Native Image][native-image] and [Truffle languages][truffle-languages].
## Key Features
This action:
-- supports GraalVM CE [releases], [dev builds][dev-builds], and [Mandrel][mandrel] (see [options](#options))
-- has built-in support for GraalVM components and the [GraalVM updater][gu]
+- supports GraalVM Community Edition (CE) [releases], [dev builds][dev-builds], GraalVM Enterprise Edition (EE) [releases][graalvm-ee] (set [`gds-token`](#options)) 22.1.0 and later, and [Mandrel][mandrel] (see [options](#options))
+- has built-in support for GraalVM components and the [GraalVM Updater][gu]
- exports a `$GRAALVM_HOME` environment variable
- adds `$GRAALVM_HOME/bin` to the `$PATH` environment variable
(Truffle languages and tools can be invoked directly)
- sets `$JAVA_HOME` to `$GRAALVM_HOME` by default
(can be disabled via `set-java-home: 'false'`, see [options](#options))
-- supports `amd64` and `aarch64` (requires a [self-hosted runner][gh-self-hosted-runners])
+- supports `amd64` and `aarch64` (requires a [self-hosted runner][gha-self-hosted-runners])
- sets up Windows environments with build tools using [vcvarsall.bat][vcvarsall]
@@ -29,7 +29,7 @@ jobs:
- uses: graalvm/setup-graalvm@v1
with:
version: 'latest'
- java-version: '11'
+ java-version: '17'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Example step
@@ -77,12 +77,43 @@ jobs:
path: helloworld*
```
+### Basic GraalVM Enterprise Edition Template
+
+#### Prerequisites
+
+1. Download the version of [GraalVM Enterprise Edition (EE)][graalvm-ee] you want to run on GitHub Actions.
+2. Use the [GraalVM Updater][gu] to install the GraalVM components you need on GitHub Actions and accept the corresponding licenses.
+3. Run `$GRAALVM_HOME/bin/gu --show-ee-token` to display your token for the GraalVM Download Service.
+4. Store this token as a [GitHub Action secret][gha-secrets]. For this template, we use the name `GDS_TOKEN`.
+
+```yml
+name: GraalVM build
+on: [push, pull_request]
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ - uses: graalvm/setup-graalvm@v1
+ with:
+ version: '22.1.0'
+ gds-token: ${{ secrets.GDS_TOKEN }}
+ java-version: '11'
+ components: 'native-image'
+ github-token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Example step
+ run: |
+ java --version
+ native-image --version
+```
+
## Options
| Name | Default | Description |
|-----------------|:--------:|-------------|
| `version`
*(required)* | n/a | `X.Y.Z` (e.g., `21.3.0`) for a specific [GraalVM release][releases]
`latest` for [latest stable release][stable],
`dev` for [latest dev build][dev-build],
`mandrel-X.Y.Z` (e.g., `mandrel-21.3.0.0-Final`) for a specific [Mandrel release][mandrel-releases],
`mandrel-latest` for [latest Mandrel stable release][mandrel-stable]. |
+| `gds-token` | `''` | Download token for the GraalVM Download Service. If a non-empty token is provided, the action will set up GraalVM Enterprise Edition (see [GraalVM EE template](#basic-graalvm-enterprise-edition-template)). |
| `java-version`
*(required)* | n/a | `'11'` or `'17'` for a specific Java version.
(`'8'` and `'16'` are supported for GraalVM 21.2 and earlier.) |
| `components` | `''` | Comma-spearated list of GraalVM components (e.g., `native-image` or `ruby,nodejs`) that will be installed by the [GraalVM Updater][gu]. |
| `github-token` | `''` | Token for communication with the GitHub API. Please set to `${{ secrets.GITHUB_TOKEN }}` (see [templates](#templates)) to allow the action to authenticate with the GitHub API, which helps to reduce rate limiting issues. |
@@ -99,8 +130,10 @@ Only pull requests from committers that can be verified as having signed the OCA
[dev-build]: https://github.com/graalvm/graalvm-ce-dev-builds/releases/latest
[dev-builds]: https://github.com/graalvm/graalvm-ce-dev-builds
-[gh-self-hosted-runners]: https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners
+[gha-secrets]: https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository
+[gha-self-hosted-runners]: https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners
[gu]: https://www.graalvm.org/reference-manual/graalvm-updater/
+[graalvm-ee]: https://www.oracle.com/downloads/graalvm-downloads.html
[mandrel]: https://github.com/graalvm/mandrel
[mandrel-releases]: https://github.com/graalvm/mandrel/releases
[mandrel-stable]: https://github.com/graalvm/mandrel/releases/latest
diff --git a/action.yml b/action.yml
index 4777298..c6ef5d6 100644
--- a/action.yml
+++ b/action.yml
@@ -1,5 +1,5 @@
name: 'GitHub Action for GraalVM'
-description: 'Set up a specific version of GraalVM Enterprise Edition (EE) or Community Edition (CE)'
+description: 'Set up a specific version of GraalVM Community Edition (CE) or Enterprise Edition (EE)'
author: 'GraalVM Developers'
branding:
icon: 'terminal'
@@ -10,7 +10,7 @@ inputs:
description: 'GraalVM version (release, latest, dev).'
gds-token:
required: false
- description: 'Download token for the GraalVM Download Service. Set this to use GraalVM EE.'
+ description: 'Download token for the GraalVM Download Service. If provided, the action will set up GraalVM Enterprise Edition.'
java-version:
required: true
description: 'Java version (11 or 17, 8 or 16 for older releases).'