![]() ![]() I understood that Kaniko is originally a project by Google. And to me, this seems like very basic requirement and use case. I have tried to find an example of that kind of scenario of Kaniko usage, and so far, it looks to me that this way of using Kaniko might not be possible at all, with Kaniko and private git repo as build context. Question : Can I use private git repository wiht Kaniko on Kubernetes? How should credentials and/or access tokens be defined and given with private repo. Here those properties (config) files are fetched from my project's git repo by Kaniko. config/my-config-2.properies /my-config-2.properties config/my-config.properies /my-config.propertiesĬOPY. With this Kaniko Docker image (pod) definition my Dockerfile can be used with Kaniko just like I can use it with Docker or docker-compose.ĭockerfile that lives in my maven project, and at this stage is pushed to git repo could look like this : FROM openjdk:11ĬOPY. "-context-sub-path=kaniko-setup/restapi/docker/", Image: gcr.io/kaniko-project/executor:latestĪrgs: [ "-context=git:///gituserxyz/kaniko-test", Like in this "kaniko-restapi.yaml" : apiVersion: v1 ![]() So I created an empty project and initialized it using git init ( documentation ). I can give to Kaniko the git repo I want to use to build my snapsoht Docker image on top of base image, given in Dockerfile build file. 1 I saw many issues in this context, and tried the solutions provided there but do not work for me for some reason. I have tested Kaniko using public GitHub repo as a build context. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |