Skip to content

Commit

Permalink
Build release candidate with Java 11
Browse files Browse the repository at this point in the history
  • Loading branch information
Abacn committed Sep 26, 2024
1 parent 91c9be4 commit 4c55be1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 16 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,14 +162,14 @@ To work around this, you can start using hosted runners and then switch over whe
You can do this by changing `runs-on: [self-hosted, ubuntu-20.04, main]` (self-hosted, use in your PR) to `runs-on: ubuntu-20.04` (GitHub hosted, use for local testing).

Note when using `ubuntu-20.04` as the host, you might need to choose the Java version since some gradle tasks only work with a certain Java version.
One example is below to use Java 8 when testing your workflow:
One example is below to use Java 11 when testing your workflow:
```
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '8'
java-version: '11'
```

## Testing Workflow Updates
Expand Down
20 changes: 6 additions & 14 deletions .github/workflows/build_release_candidate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ jobs:
with:
ref: "v${{ github.event.inputs.RELEASE }}-RC${{ github.event.inputs.RC }}"
repository: apache/beam
- name: Install Java 8
- name: Install Java 11
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '8'
java-version: '11'
- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@111c56156bcc6918c056dbef52164cfa583dc549
Expand Down Expand Up @@ -114,11 +114,11 @@ jobs:
then
echo "Must provide an apache password to stage artifacts to https://dist.apache.org/repos/dist/dev/beam/"
fi
- name: Install Java 8
- name: Install Java 11
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '8'
java-version: '11'
- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@111c56156bcc6918c056dbef52164cfa583dc549
Expand Down Expand Up @@ -264,14 +264,6 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.9'
- run: echo $JAVA_HOME
- run: echo "JAVA11_HOME=${JAVA_HOME}" >> "$GITHUB_OUTPUT"
id: export-java11
- name: Install Java 8
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '8'
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Remove default github maven configuration
Expand Down Expand Up @@ -318,11 +310,11 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '16'
- name: Install Java 8
- name: Install Java 11
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '8'
java-version: '11'
- name: Remove default github maven configuration
# This step is a workaround to avoid a decryption issue of Beam's
# net.linguica.gradle.maven.settings plugin and github's provided maven
Expand Down

0 comments on commit 4c55be1

Please sign in to comment.