Skip to content

CLI Pods? Where we're going we don't need CLI pods. (v0.23.0)

Compare
Choose a tag to compare
@Schnitzel Schnitzel released this 28 May 22:19

This release has one big focus: idling CLI pods and cluster load overall. Currently we keep CLI pods alive in order for them to run Cron Jobs and do backups for shared MariaDB in coordination with k8up. But this means we have many pods running which are not really necessary, so this release changes that:

  1. Cron Jobs are now not running in CLI Pod anymore, but instead we use Native Kubernetes CronJob objects. These CronJob will start a pod for each run which is then removed again. This reduces the load on the cluster dramatically and should free up some resources in our bigger clusters. One important thing: if there is a cronjob defined that runs more often than every 15mins, we still create them inside the CLI pods as the native CronJob objects would put too much load on the cluster if we start a new pod every minute.
  2. k8up (our BaaS System) has now support for PreBackupPods. Which allows k8up to start a new pod during the backup. Until now we used the CLI pods to provide backups from a shared MariaDB system. Now k8up starts a pod during the backup which is also removed after the backup has finished.
    These two changes allow Lagoon to idle CLI pods and therefore reduce the Cluster load. They are of course automatically started again during pre- and post-deploy tasks and if somebody connects via SSH.

Another notable change regarding cluster load is the switch from exec readiness and liveness checks, to tcpSocket for php containers. Up until now we used small shell scripts to check the health of php containers. Unfortunately we see on Kubernetes/OpenShift Clusters with bigger nodes (100+ pods per node), that the performance of the kubelet and Docker daemon can drastically decrease as exec checks run an actual docker exec, which for big nodes can end up with 50 docker exec per second (!). Using tcpSocket checks does not put any load on the Docker daemon and should allow the clusters overall to run much smoother.

Features:

  • Support for PreBackupPods together with k8up #1097
  • Script to locate orphaned Ansible service broker Mariadb databases #1079

Changes:

  • Idle CLI pods that don't have any cronjobs defined. If a cron is less often than 15 minutes, run it in a cronjob type rather than in the existing pod. #1031 #1105 #1106
  • Allows the python-ckandatapusher image to have a configurable port #1071
  • Create a new python-ckandatapusher service type that listens on the existing port #1071
  • Update to composer v1.8.5 in php-cli Images #1041
  • Update Drush v8.2.2 to v8.2.3 in php-cli Images #1024
  • Update Drupal Console to 1.8.0 #1011

Bugfixes:

  • Fix typo in typeDefs.js #1084
  • Removed $ character from slack logs notification link #1073
  • Fix problems when using SSH keys with a non-root users. #1033
  • Fix UI subscriptions #1014
  • Fixing curator runs by making sure .bashrc is sourced for cronjobs #1010

Improvements:

  • Added icons in UI for "dev env in use" and task files #1095
  • Solr Drupal 7.5: correct solr.install.dir in solrcore.properties file #1094
  • Updated dsql and dfiles aliases #1092
  • Replace gatter with gather #1087
  • Added timeout to exit from the possible never ending loop when provisioning shared mariadb #1086
  • Updating liveness and readiness checks for PHP to use TCPsocket #1085
  • add findutils to php-cli image #1077
  • Allow dashboard log container to be "full height" #1065
  • Update gitlabProjectCreate webhook handler to correctly create Project #1055
  • docker-host pruning is more thorough by removing all images older than 7 days, additionally we take care of potentially exited containers that prevented cleanup #1053
  • Auto Idler checks if there are any running builds for a project, and also if there are any processes running beyond the entrypoint #1039
  • support for WebP in php-fpm images #1029
  • docker-host: Use extended regex to allow use of pipes in REPOSITORY_TO_UPDATE variable #1027
  • Each API request will generate a new MariaDB connection #1012
  • Ensure the searchguard init script is only run on initial deployment #908

Documentation:

  • fix graphql query #1081
  • Better Documentation of the addProject mutation #1080
  • Make the contrib guidelines easier accessable #1078
  • document Drush 9 alias generation #1068
  • fixed link to GraphQL API #1056
  • Mention VirtualBox requirement on the Development Setup page #1054
  • Styling improvements #1043
  • Ignoring the site directory when building the documentation locally #1043
  • fixed broken document links #1037
  • Improved MySQL Documentation #1035
  • Adding remarks to .lagoon.yml #1015