Since (almost) all managed hosts have SSH certificates signed by SSHCA now, the need to maintain a pseudo-dynamic SSH key list is winding down. If we include the SSH CA key in the global known hosts file, and explicitly list the couple of hosts that do not have a certificate, we can let Ansible use that instead of fetching the host keys on each run. |
||
---|---|---|
.. | ||
README.md | ||
argocd-sync-hook.yaml | ||
jenkins.yaml | ||
kustomization.yaml | ||
secrets.yaml | ||
ssh_known_hosts |
README.md
Jenkins in Kubernetes
Kubernetes Setup
Configure Jenkins resources:
ln imagepull-gitea jenkins/.dockerconfigjson
kubectl apply -k jenkins
Jenkins Setup
Install Kubernetes plugin.
Set TCP port for inbound agents setting (Manage Jenkins → Configure Global
Security) to Fixed and enter 40414
.
Configure Kubernetes (Manage Jenkins → Manage Nodes and Clouds → Configure Clouds:
- Add a new cloud → Kubernetes
- Enter a name
- Kubernetes Cloud details...
- Kubernetes URL: (leave blank; will use Kubernetes service discovery)
- Kubernetes Namespace:
jenkins-jobs
- Credentials:
- none -
(will use Service Account token) - Jenkins tunnel:
jenkins.jenkins.svc.cluster.local:
(trailing colon!)