Add cacerts parameter, which can copy existing cacerts into JDK

This commit is contained in:
Michal Dvorak 2022-01-17 17:11:15 +01:00 committed by Michal Dvořák
parent d53b046579
commit 0d42bcacb6
No known key found for this signature in database
GPG key ID: 42E7AE26FA8092D2
11 changed files with 2167 additions and 2075 deletions

View file

@ -120,6 +120,19 @@ steps:
- run: java -cp java HelloWorldApp
```
## Using existing cacerts file
In enterprise environment, custom CA truststore is often used. By specifying source file action can copy the `cacerts`
into new Java installation automatically.
```yaml
- uses: actions/setup-java@v2
with:
distribution: '<distribution>'
java-version: '11'
cacerts: '/etc/ssl/certs/java/cacerts'
- run: java -cp java HelloWorldApp
```
## Testing against different Java distributions
**NOTE:** The different distributors can provide discrepant list of available versions / supported configurations. Please refer to the official documentation to see the list of supported versions.
```yaml