docker - Kubernetes: how to use gitRepo volume? -


can give example of how use gitrepo type of volume in kubernetes?

the doc says it's plugin, not sure means. not find example anywhere , don't know proper syntax.

especially there parameters pull specific branch, use credentials (username, password, or ssh key) etc...

edit: going through kubernetes code figured far:

- name: data   gitrepo:     repository: "git repo url"     revision:   "hash of commit use" 

but can't seen make work, , not sure how troubleshoot issue

this sample application used:

{   "kind": "replicationcontroller",   "apiversion": "v1",   "metadata": {     "name": "tess.io",     "labels": {       "name": "tess.io"     }   },   "spec": {     "replicas": 3,     "selector": {       "name": "tess.io"     },     "template": {       "metadata": {         "labels": {           "name": "tess.io"         }       },       "spec": {         "containers": [           {             "image": "tess/tessio:0.0.3",             "name": "tessio",             "ports": [               {                 "containerport": 80,                 "protocol": "tcp"               }             ],             "volumemounts": [               {                 "mountpath": "/tess",                 "name": "tess"               }             ]           }         ],         "volumes": [           {             "name": "tess",             "gitrepo": {               "repository": "https://<token>:x-oauth-basic@github.com/tess/tess.io"             }           }         ]       }     }   } } 

and can use revision too.

ps: repo above not exist anymore.


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

Delphi 7 and decode UTF-8 base64 -

html - Is there any way to exclude a single element from the style? (Bootstrap) -