update docs for interative shell instructions

master
JoYo 2021-02-18 15:02:31 -05:00
parent d991173e56
commit 25b97d8a79
3 changed files with 27 additions and 9 deletions

View File

@ -6,8 +6,8 @@ Powershell scripts are included to try and recreate these build environments dir
# Requirements # Requirements
A Windows 10 workstation or VM with minimum 8 GB of memory is required. A Windows 10.0.19041.804+ workstation or VM with minimum 8 GB of memory is required.
The more concurrent containers you have running, the more memory and CPU cores is required. The more concurrent containers you have running, the more memory and CPU cores are required.
**Each container requires one core and approximately 4 GB of memory.** **Each container requires one core and approximately 4 GB of memory.**
@ -48,19 +48,16 @@ Below is an example `docker-compose.yaml` file used to build a project configure
version: '3' version: '3'
services: services:
win64_build_release: win_build:
image: win_build image: win_build
volumes: volumes:
- .:C:/source/ - .:C:/source/
command: msbuild .
``` ```
- `volumes:` are mounted within the Docker container. - `volumes:` are mounted within the Docker container.
- `C:/source/` is assumed to be the project being build with MSVC. - `C:/source/` is assumed to be the project being build with MSVC.
- `command:` passes arguments to `Microsoft.VisualStudio.DevShell` unless entrypoint is otherwise defined.
To build a Windows XP project use the `image: winxp_build` container image. To build a Windows XP project use the `image: winxp_build` container image.
# Build Your Windows Project # Build Your Windows Project
@ -69,7 +66,28 @@ The above `docker-compose.yaml` file should be stored within your project and wi
Once this file is created within your project run the following command to begin the build process. Once this file is created within your project run the following command to begin the build process.
```bash ```bash
docker-compose up docker-compose run win_build
```
This will drop you into the visual studio developer shell or console for winxp.
To modify the developer shell environments replace `command:` in your `docker-compose.yaml` with the desired environment variables or scripted build commands.
```
version: '3'
services:
win_build:
image: win_build
volumes:
- .:C:/source/
command: powershell -NoExit -Command Import-Module C:\\msvc\\Common7\\Tools\\Microsoft.VisualStudio.DevShell.dll; Enter-VsDevShell -Verbose -VsInstallPath C:\\msvc\\
winxp_build:
image: winxp_build
volumes:
- .:C:/source/
command: cmd /k C:\\msvc\\Common7\\Tools\\VsDevCmd.bat
``` ```
# Optional Workstation Scripts # Optional Workstation Scripts

View File

@ -2,6 +2,6 @@
"version": "1.0", "version": "1.0",
"components": [ "components": [
"Microsoft.VisualStudio.Workload.VCTools", "Microsoft.VisualStudio.Workload.VCTools",
"Microsoft.VisualStudio.ComponentGroup.NativeDesktop.WinXP", "Microsoft.VisualStudio.ComponentGroup.NativeDesktop.WinXP"
] ]
} }

View File

@ -2,6 +2,6 @@
"version": "1.0", "version": "1.0",
"components": [ "components": [
"Microsoft.VisualStudio.Workload.VCTools", "Microsoft.VisualStudio.Workload.VCTools",
"Microsoft.VisualStudio.Component.NuGet", "Microsoft.VisualStudio.Component.NuGet"
] ]
} }