├── .devcontainer ├── Dockerfile └── devcontainer.json └── README.md /.devcontainer/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM mcr.microsoft.com/devcontainers/base:alpine-3.18 2 | 3 | RUN apk update 4 | RUN apk add bash \ 5 | git \ 6 | make \ 7 | mingw-w64-gcc \ 8 | i686-mingw-w64-gcc \ 9 | nano \ 10 | nasm \ 11 | vim 12 | 13 | -------------------------------------------------------------------------------- /.devcontainer/devcontainer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "svrt_musl_image", 3 | "build": { 4 | "dockerfile": "Dockerfile", 5 | "context": ".." 6 | }, 7 | "settings": { 8 | "terminal.integrated.shell.linux": "/bin/bash", 9 | "C_Cpp.default.compilerPath": "/usr/bin/x86_64-w64-mingw32-gcc" 10 | }, 11 | 12 | "customizations": { 13 | "vscode": { 14 | "extensions": [ 15 | "ms-vscode.cpptools", 16 | "ms-vscode.cpptools-extension-pack" 17 | ] 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # BOF_Development_Docker 2 | 3 | ## Summary 4 | 5 | This repository serves as a fully functional, **lightweight** template for developing and compiling `BOF` or otherwise `Windows`-centric applications via `Visual Studio Code`. 6 | 7 | ## Why 8 | 9 | `Visual Studio Code` has supported idempotent, purpose-built containers for development for a few years. 10 | 11 | This is meant to illustrate on how powerful this is, namely: 12 | - Remote installation of extension configurations 13 | - Reliable `Intellisense` for development using path inspection 14 | - Quick, reliable, readily deployable images for rapid development 15 | - Lack of configuration drift between traditional virtual machine IDEs 16 | 17 | ## How 18 | 19 | Opening this folder within `Visual Studio`, you will be prompted to reopen within a container. 20 | 21 | Acknowledging this (and assuming you have the [Docker VSCode extension](https://code.visualstudio.com/docs/containers/overview), and `Docker` already installed) will reload the current window to be *inside* of the container it has built for you. That's it. Happy hacking. 22 | 23 | ## Elections and Benefits 24 | 25 | I'm currently using `musl` as the set of header files/libraries/compiler options. This plays a *lot* nicer with the numerous hacks of function pointers leveraged within many popular projects, to include reflective loaders of choice. 26 | 27 | We're running on a slim `Alpine` image due to its size and first-class support of `musl` natively. This is just one less headache, and we can leave the "kitchen sink" bloat of other images. 28 | 29 | The configuration of the extensions is already done for you, so `Intellisense` among other things (such as peeking definitions) is a single right-click away. --------------------------------------------------------------------------------