Docker Desktop Dive extension
Sandip Chitale
Sr. Software Engineer @ Apple | Proficient in Angular+Primeng, Springboot,Helm/Kubernetes
UPDATE: Lots of improvements.
It is always interesting to explore the layers of a Docker image and optimize the layers. It is also interesting how each layer affects the file system at runtime. Well, the Dive tool exactly does that.
Recently I have been exploring the Extension SDK for Docker Desktop. So I thought it will be cool to write and extension that integrates Dive tool with the Docker Desktop. So that is what I did. Here is the extension running inside Docker Desktop.
It lists the images and the container. You can click on the Dive button to invoke the Dive tool on the image or the image running in the container. The list of images and containers is obtained using the API provided by Docker Desktop extension SDK. Here is the terminal based UI of Dive tool which you can use to explore the layers on the left side and effects of each layer on file system on the right side.
I also wanted to see if it will be able possible to implement the extension using Angular 18 with PrimeNG 18 with TailwindCSS. I was happy to figure it out.
One thing I noticed though was, to make PrimeNG themeing to work, I had to set the theme this way (actually there is issue for this https://github.com/primefaces/primeng/issues/16785) :
import {providePrimeNG} from 'primeng/config';
import Aura from '@primeng/themes/aura';
:
:
:
export const appConfig: ApplicationConfig = {
providers: [
:
providePrimeNG({
// theme: Aura <----------------- does not work
theme: { // <--------------------- this works!
preset: Aura,
options: {
prefix: 'p',
darkModeSelector: '.dark-theme'
}
},
ripple: true
})]
};
The code for Docker Desktop Docker extension is in this GihHub repository. Currently only works on Linux and Windows.
If anyone wants to try this extension, just do the following:
docker extension install sandipchitale/docker-desktop-dive:1.0.0 -f
I have pushed the Docker images to Docker Hub so you should be able to try them by doing:
> docker pull sandipchitale/...:1.0.0
> docker extension install sandipchitale/...:1.0.0
Feedback welcome!
Be productive!