Including files (NOT classpath resource) in Quarkus Native

855 views Asked by At

In Quarkus, to include random files as classpath resource, we use quarkus.native.resources.includes (https://quarkus.io/guides/writing-native-applications-tips#including-resources).

How to include files in the file system? I.e. something read using new File(thePath).

If we use Jib, we simply put those files inside src/main/jib. But that's for non-native.

1

There are 1 answers

0
geoand On BEST ANSWER

Building a native binary has nothing to do with adding files to the file system of the target platform.

If your goal is to create a container image using the native binary and also add files to the container image's filesystem, then you can use Quarkus with Jib and the files to src/main/jib (as you mentioned). These files will be included on the built container image as described here.