From 250e9efdf5da3b44edf89a13d18e4f671b35d0ef Mon Sep 17 00:00:00 2001 From: Brandt Keller Date: Thu, 4 Apr 2024 01:14:34 +0000 Subject: [PATCH 1/5] Draft: begin developer environment post --- content/posts/draft/dev-machine-refresh.md | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 content/posts/draft/dev-machine-refresh.md diff --git a/content/posts/draft/dev-machine-refresh.md b/content/posts/draft/dev-machine-refresh.md new file mode 100644 index 0000000..e627147 --- /dev/null +++ b/content/posts/draft/dev-machine-refresh.md @@ -0,0 +1,29 @@ +--- +title: "Developer Environment Experiment - Developing solely in Containers" +date: 2024-04-04T05:30:00-07:00 +tags: ["Development", "Productivity"] +series: "Development" +draft: true +--- + +## Setting the Stage + +In a week of the news around xz utils backdoor vulnerabilitity, it provides a reminder that there are systems that we need to remain vigilant in monitoring. + +I'm a believer that one of our most vulnerable assets is our developer environments. We conduct tons of experimentation and use them to drive upgrades to downstream systems. + +How are we keeping track of what is installed and the versions etc? seems like a solved problem - but I can guarantee that even big enterprise still remains vulnerable - more so in the age of containers. + +Now take startup culture where the full spectrum of secure to wild west is a real possibility (I can sleep soundly knowing my organization is likely forward leaning in security here, although that may not have always been the case). + +## Target Acquired + +I have a development system that's been in continual daily-use for multiple years now. Experimentation across many open-source projects and ideas that have sprung into something executable. Many languages - many package managers - etc etc. + + + +## Step 1 - Plan + +## Step 2 - "rm -rf /*" + +## Step 3 - Use Ephermeral as a feature \ No newline at end of file From d1a8e24a8d746e4c7e78a53b31267e68dee27431 Mon Sep 17 00:00:00 2001 From: Brandt Keller Date: Thu, 4 Apr 2024 03:18:19 +0000 Subject: [PATCH 2/5] draft: more content for article --- content/posts/draft/dev-machine-refresh.md | 29 ++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/content/posts/draft/dev-machine-refresh.md b/content/posts/draft/dev-machine-refresh.md index e627147..524d83a 100644 --- a/content/posts/draft/dev-machine-refresh.md +++ b/content/posts/draft/dev-machine-refresh.md @@ -20,10 +20,35 @@ Now take startup culture where the full spectrum of secure to wild west is a rea I have a development system that's been in continual daily-use for multiple years now. Experimentation across many open-source projects and ideas that have sprung into something executable. Many languages - many package managers - etc etc. - +Things add-up on the filesystem - even if you attempt to cleanup. Multiple projects in motion concurrently means that there may be a lot of in-progress ideas stored up. ## Step 1 - Plan +I operate on GitHub day in and day out. Which means that If I am committing early and often - the idea of losing my work is quite small. I wanted to use this to my advantage. Looking at dev-containers, I knew there was something I wanted to leverage - but the project-specific nature was a bit of a hurdle. I needed something more general purpose. + +So why not just develop with containers in a semi-persistent manner? The dev-containers extension for vscode actually does a lot in the way of compatability and credentials for things like git. + +So what is the best way to commit to an experiment? wipe the machine. + ## Step 2 - "rm -rf /*" -## Step 3 - Use Ephermeral as a feature \ No newline at end of file +Did my work for the day - backed up any relevant data that I may want to cherry-pick in the future and then wiped the machine. + +let's start over. + +## Step 3 - Bare Essentials + +All I wanted to install on the host itself was the bare essentials. +- VScode +- Minimum Extensions (dev-containers, remote-ssh) +- Docker + +## Step 4 - Use Ephermeral as a feature + +Now the guiding principals for developing within containers. If I am not mounting any persistent volumes, then any time I remove this container from running - all the ephemeral data is gone. + +This is extermely valuable to me in constant experimentation. Installing some new package or dependency - no need to remember to come back and remove it afterwords. At a minimum, when I update the container (on some established cadence), then it'll be gone anyway. + +## Step 5 - Container Focus + +Talk about the repository. \ No newline at end of file From 51bbbd6630140cebd2482f2672808d1e07797f08 Mon Sep 17 00:00:00 2001 From: Brandt Keller Date: Fri, 5 Apr 2024 15:25:09 +0000 Subject: [PATCH 3/5] Draft: dev machine refresh --- content/posts/draft/dev-machine-refresh.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/content/posts/draft/dev-machine-refresh.md b/content/posts/draft/dev-machine-refresh.md index 524d83a..a02ab14 100644 --- a/content/posts/draft/dev-machine-refresh.md +++ b/content/posts/draft/dev-machine-refresh.md @@ -1,6 +1,6 @@ --- title: "Developer Environment Experiment - Developing solely in Containers" -date: 2024-04-04T05:30:00-07:00 +date: 2024-04-05T05:30:00-07:00 tags: ["Development", "Productivity"] series: "Development" draft: true @@ -51,4 +51,15 @@ This is extermely valuable to me in constant experimentation. Installing some ne ## Step 5 - Container Focus -Talk about the repository. \ No newline at end of file +From here - it's all about tracking required tooling and development environments with separation that makes sense in day to day. + +Currently experimenting with a few different builds that all stem from a common base image. See the [repository]() for more information. + +Runtime of the containers can be as continuous as required - from simply a shell to a container that runs continuosly that I can connect to with VSCode. Think separate-isolated developmetn environments by language (go, python, javascript) or purpose (CLI, Kubernetes, etc). + +## Conclusion +I've gloseed over quite a bit of the actual details in how this all coalesces together. How the VSCode workflow handles complexities such as gitconfig, ssh keys and other processes like allowing signed commits without having anything built-into the container itself. + +I'll dive more into those in future topics. Right now - I'll continue to experiment and look at what is really necessary for daily development - as well as using this same workflow to develop on beefier machines and treat my laptop as a thin-client of sorts. + +More to come! thanks for reading. \ No newline at end of file From 95008c7a6e9a0142e7a327d185c3aaaf56f3810e Mon Sep 17 00:00:00 2001 From: Brandt Keller Date: Fri, 5 Apr 2024 15:30:08 +0000 Subject: [PATCH 4/5] fix: repository link --- content/posts/draft/dev-machine-refresh.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/content/posts/draft/dev-machine-refresh.md b/content/posts/draft/dev-machine-refresh.md index a02ab14..5b20678 100644 --- a/content/posts/draft/dev-machine-refresh.md +++ b/content/posts/draft/dev-machine-refresh.md @@ -43,6 +43,8 @@ All I wanted to install on the host itself was the bare essentials. - Minimum Extensions (dev-containers, remote-ssh) - Docker +As far as developpment goes... that's it. + ## Step 4 - Use Ephermeral as a feature Now the guiding principals for developing within containers. If I am not mounting any persistent volumes, then any time I remove this container from running - all the ephemeral data is gone. @@ -53,7 +55,7 @@ This is extermely valuable to me in constant experimentation. Installing some ne From here - it's all about tracking required tooling and development environments with separation that makes sense in day to day. -Currently experimenting with a few different builds that all stem from a common base image. See the [repository]() for more information. +Currently experimenting with a few different builds that all stem from a common base image. See the [repository](https://github.com/brandtkeller/dev-env) for more information. Runtime of the containers can be as continuous as required - from simply a shell to a container that runs continuosly that I can connect to with VSCode. Think separate-isolated developmetn environments by language (go, python, javascript) or purpose (CLI, Kubernetes, etc). From fc696ed273b21823620517d0d9816b007ae572ef Mon Sep 17 00:00:00 2001 From: Brandt Keller Date: Fri, 5 Apr 2024 15:31:17 +0000 Subject: [PATCH 5/5] Publish: dev env experiment --- content/posts/{draft => development}/dev-machine-refresh.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename content/posts/{draft => development}/dev-machine-refresh.md (99%) diff --git a/content/posts/draft/dev-machine-refresh.md b/content/posts/development/dev-machine-refresh.md similarity index 99% rename from content/posts/draft/dev-machine-refresh.md rename to content/posts/development/dev-machine-refresh.md index 5b20678..baf4686 100644 --- a/content/posts/draft/dev-machine-refresh.md +++ b/content/posts/development/dev-machine-refresh.md @@ -3,7 +3,7 @@ title: "Developer Environment Experiment - Developing solely in Containers" date: 2024-04-05T05:30:00-07:00 tags: ["Development", "Productivity"] series: "Development" -draft: true +draft: false --- ## Setting the Stage