Skip to content

Use pre-existing JDK installations #28

@sebthom

Description

@sebthom

I would like to use vfox on github action runners in a way that in case a JDK is already installed vfox does not download the JDK again but the pre-installed one can be registered into vfox.

I would like to be able to do something like this:

# in a initial step I search for installed JDKs and register them with vfox
vfox register java@11-tem /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk/11.0.27-6
vfox register java@21-tem /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk/21.0.3

# in later steps I want to call `vfox install java` via some external bash script like this:
vfox install java@11-tem  # should be a no-op since already installed
vfox install java@21-tem  # should be a no-op since already installed
 # query the install dirs of multiple JDKs so I can reference them in Maven's toolchains.xml
JAVA_11_HOME=$(vfox home java@11-tem) 
JAVA_21_HOME=$(vfox home java@21-tem) 

Is this already possible somehow? If not could something like this be added?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions