Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Building Windows Containers with AWS CodeBuild

I'm getting started with the CI/CD functionality of AWS. To this point, I have been creating my docker image locally on Windows Server 2016, based on the microsoft/windowsservercore image, and manually pushing it to the ECR (amazon container registry).

At this point, I'm not trying to compile the application in CodeBuild. I'm only trying to build the container. Locally, the binaries are in a sub-directory and copied into the container.

The CodeBuild project is failing with an error: image operating system "windows" cannot be used on this platform

I'm pretty sure that's because the build environment is linux based.

Does anyone know if it's possible to create a Custom Build Environment for AWS that would support building a Windows container image?

like image 524
Nick Avatar asked Apr 27 '26 16:04

Nick


1 Answers

AWS CodeBuild does not support a Windows build environment, but it is in the works. You can sign up here for notifications about CodeBuild support for Windows.

However, CodeBuild runs all builds on Docker. Building Docker images in a Windows Docker container is not yet supported by Microsoft (see this GitHub issue for details).

like image 177
Clare Liguori Avatar answered Apr 30 '26 14:04

Clare Liguori



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!