I am working on a gradle based service that should run in a docker container in a kubernetes cluster. Locally, I can access the resources, some json files used for CouchDb initialisation. Once I build and deploy the service in Docker, the files are no longer accessible and I get file not found exception and can't start the service. I can see that my folder is in the generated jar but I can't access the files. I am using it like follows:
DesignDocument design = DesignDocumentManager.fromFile("design-documents/documents.json");
which comes from the IBM Cloudant Java Client API. I have tried different versions from the path, i.e. with a leading slash or the absolute path from the project.