Geeking in technology since 1985, with IBM Development, focused upon Docker and Kubernetes on the IBM Z LinuxONE platform In the words of Dr Cathy Ryan, "If you don't write it down, it never happened". To paraphrase one of my clients, "Every day is a school day". I do, I learn, I share. The postings on this site are my own and don’t necessarily represent IBM’s positions, strategies or opinions. Remember, YMMV https://infosec.exchange/@davehay
Thursday, 28 October 2021
Apple Watch - stop talking to me
Tuesday, 26 October 2021
Podman and IBM Container Registry - there's more ...
Following on from my most recent Podman-related posts I'm creating an image to test my RedHat OpenShift Kubernetes Service (ROKS) deployment.
Given that I'm living in the IBM Cloud CLI, I thought I'd try the ic cr command-line: -
ic cr build --no-cache de.icr.io/roks_oct2021/hello_world:latest --file Dockerfile .
FAILED
The 'build' command is deprecated, you must specify the --accept-deprecation option to use this command. For more information see: https://www.ibm.com/cloud/blog/announcements/ibm-cloud-container-registry-deprecating-container-builds
Aw shucks, of course ...
Thankfully, I have Podman ...
podman build --no-cache -t de.icr.io/roks_oct2021/hello_world:latest -f Dockerfile .
and then, having created myself a namespace in ICR: -
ic cr namespace-add roks_oct2021
I can push the image: -
podman push de.icr.io/roks_oct2021/hello_world:latest
and we're off to the races ...
ic cr images
Listing images...
Repository Tag Digest Namespace Created Size Security status
de.icr.io/roks_oct2021/hello_world latest 029263beb4d4 roks_oct2021 43 minutes ago 16 MB No Issues
OK
Ooops, Podman broke my IBM Container Registry - well, kinda
I was digging into an IBM Container Registry (ICR), specifically to look at an image that I'd just built/pushed.
This is on a Mac upon which I've installed Podman, to replace Docker Desktop, as per previous posts.
Having logged into IBM Cloud ( I have a script for that ), I logged into the ICR instance: -
ic cr login
which responded: -
Logging in to 'us.icr.io'...
FAILED
Failed to 'docker login' to 'us.icr.io' with error: Cannot connect to Podman. Please verify your connection to the Linux system using `podman system connection list`, or try `podman machine init` and `podman machine start` to manage a new Linux VM
Error: unable to connect to Podman. failed to create sshClient: Connection to bastion host (ssh://core@localhost:53095/run/user/1000/podman/podman.sock) failed.: dial tcp [::1]:53095: connect: connection refused
At which point, I realised where I'd gone wrong - I'd rebooted my Mac since last I did this, and, at a guess, the Podman Machine doesn't autostart.
I manually started it: -
podman machine start
INFO[0000] waiting for clients...
INFO[0000] listening tcp://0.0.0.0:7777
INFO[0000] new connection from to /var/folders/b5/8vqr9tt54v94jxzs0_k2qq2m0000gn/T/podman/qemu_podman-machine-default.sock
Waiting for VM ...
Machine "podman-machine-default" started successfully
and then attempted to log into ICR: -
ic cr login
Logging in to 'us.icr.io'...
Logged in to 'us.icr.io'.
OK
Monday, 25 October 2021
IBM Cloud - OCP clusters, Ingress and Certificate Manager
So this is definitely a work-in-progress but I may have resolved an issue that I was seeing with a newly created OpenShift Container Platform (OCP) cluster.
TL;DR; the command ic cs cluster ls showed my cluster state as warning and never as ready.
When I inspected the cluster using ic cs cluster get --cluster $cluster_name I saw: -
Ingress Subdomain: - †
Ingress Secret: - †
Ingress Status: -
Ingress Message: -
and: -
† Your Ingress subdomain and secret might not be ready yet. For more info by cluster type, see 'https://ibm.biz/ingress-sub' for Kubernetes or 'https://ibm.biz/ingress-sub-ocp' for OpenShift.
Today I learned - one reason why one may not be able to authenticate to a RedHat OpenShift cluster running on IBM Cloud ...
Today I mainly be tinkering with RedHat OpenShift Container Platform (OCP) on IBM Cloud, and am running through a set of steps that I've written to document the end-to-end setup.
Having created a cluster on Friday, I tried to authenticate to it today: -
export apikey="my_api_key_goes_here"
oc login https://control-plane-endpoint-url:31452 -u apikey -p $apikey
but this threw up: -
Error from server (InternalError): Internal error occurred: unexpected response: 500
Saturday, 16 October 2021
Yay, VMware Fusion and macOS Big Sur - no longer "NAT good friends" - forgive the double negative and the terrible pun ...
After macOS 11 Big Sur was released in 2020, VMware updated their Fusion product to v12 and, sadly, managed to break Network Address Translation (NAT), as per their release notes: -
VMware Fusion 12 Release Notes
On Big Sur hosts, if user configures NAT port forwarding in Fusion, the service running in the virtual machine is unavailable on the macOS host using localhost:exposedPort, hostIP:exposedPort, or 127.0.0.1:exposedPort; Port forwarding is also not accessible inside a NAT virtual machine using hostIP:exposedPort.
Thankfully, as of now, with Fusion 12.2.0 this is now resolved: -
VMware Fusion 12.2.0 Release Notes
Wednesday, 13 October 2021
For my future self - don't try and use crictl to deploy pods into an existing Kubernetes cluster
I'm doing some work with the Kata Containers v2 runtime, and was trying to test it using crictl
First I created a pair of YAML documents: -
metadata:
attempt: 1
name: busybox-sandbox
namespace: default
uid: hdishd83djaidwnduwk28bcsb
log_directory: /tmp
linux:
namespaces:
options: {}
EOF
{
"metadata": {
"name": "busybox"
},
"image":{
"image": "busybox"
},
"command": [
"top"
],
"log_path":"busybox.log",
"linux": {
}
}
EOF
and then I used the first of those to create a Pod Sandbox: -
sandbox=$(crictl runp -r kata podsandbox-config.yaml)
However, the resulting pod soon disappeared - I managed to check its state before it disappeared: -
crictl pods | grep kata
9fafade8c3216 23 seconds ago NotReady busybox-sandbox default 1 kata
65fc059b8129d 40 minutes ago Ready nginx-kata default 0 kata
and inspected the NotReady pod: -
crictl inspectp 9fafade8c3216 | jq .status.state
"SANDBOX_NOTREADY"
Note to self - Firefox and local connections
Whilst trying to hit my NAS from Firefox on my Mac, I kept seeing errors such as:- Unable to connect Firefox can’t establish a connection t...
-
Error "ldap_sasl_interactive_bind_s: Unknown authentication method (-6)" on a LDAPSearch command ...Whilst building my mega Connections / Domino / Portal / Quickr / Sametime / WCM environment recently, I was using the LDAPSearch command tha...
-
Having created a new user on an Ubuntu 16.04 boxen, I started seeing this: - Received disconnect from 192.168.3.123 port 22:2: Too many au...
-
I'm tinkering with a tool that uses pip and python, and was seeing: - zsh: /usr/local/bin/pip: bad interpreter: /usr/bin/python: no such...
