No description
  • Perl 97.4%
  • Dockerfile 2.6%
Find a file
2025-09-19 09:23:42 +02:00
Dockerfile add all files 2025-08-23 11:10:52 +02:00
fishies add all files 2025-08-23 11:10:52 +02:00
k8s-fishies-terminal-deployment.yaml add all files 2025-08-23 11:10:52 +02:00
README.md typo in readme 2025-09-19 09:23:42 +02:00
screenshot.png add screenshot 2025-08-23 13:25:28 +02:00

k8s asciiquarium (a cluster full of fishies)

you can find the original source for the fishies here: https://github.com/cmatsuoka/asciiquarium

Dockerfile

  • the dockerfile build a container, based on the latest ubuntu image that
  • create a non-root user fish with no password
  • copies the fishies script into the user's home directory
  • installs essential packages include the perl module Term::Animation
  • adjusts the ssh serverconfiguration to:
    • allow empty password
    • restrict ssh access for user fishto only run /home/fish/fishies
  • prepares the ssh runtime directory
  • runs sshd in the foreground as the container entrypoint

build and push the docker image to your registry

docker build -t docker_image:1.0.0 . -f Dockerfile

docker push docker_image:1.0.0

kubernetes manifests

  • deployment: runs one replica of the terminal-fishies container with sshd as the entrypoint. it uses a private registry secret (regcred) to pull the image.
  • secret: create secret generic regcred --from-file=.dockerconfigjson=/home/<your userhome>/.docker/config.json --type=kubernetes.io/dockerconfigjson
  • service: exposes the pod via a NodePort service on port 30288, mapping to the container’s SSH port (22).

deploy the docker image to your k8s cluster

kubectl apply -f k8s-fishies-terminal-deployment.yaml

the funny part

ssh fish@<node-ip> -p 30288

Screenshot