$ brew install kubectl
$ brew cask install virtualbox
$ brew install helm
Helm v3 is strongly recommended
⚠️
$ helm repo add stable https://kubernetes-charts.storage.googleapis.com
$ ./build.sh
Jenkins credentials: admin/admin 🚨
podTemplate(label: 'jenkins-slave-base-pod', serviceAccount: 'jenkins', containers: [
containerTemplate(
name: 'base',
image: 'sergiomartins8/jenkins-slave-base:latest',
ttyEnabled: true,
command: 'cat'
)
],
volumes: [
hostPathVolume(mountPath: '/var/run/docker.sock', hostPath: '/var/run/docker.sock')
]
) {
node('jenkins-slave-base-pod') {
stage('Awesome stage') {
container('base') {
sh 'kubectl get po'
sh 'helm env'
}
}
}
}
Checkout the complete article here.