Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 37 additions & 2 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,52 @@ jobs:
os: windows-2022
- tag: windows-2022
os: windows-2022
- tag: 2025
os: windows-2025
- tag: windows-2025
os: windows-2025
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4

# Free disk space by removing pre-installed software we don't need
- name: Free disk space
run: |
Write-Host "Disk space before cleanup:"
Get-PSDrive C | Select-Object Used, Free | Format-Table
$paths = @(
'C:\Android',
'C:\Program Files\dotnet',
'C:\Program Files\MongoDB',
'C:\Program Files\PostgreSQL',
'C:\Selenium',
'C:\hostedtoolcache',
'C:\Program Files\Microsoft Visual Studio',
'C:\vcpkg',
'C:\Miniconda',
'C:\Program Files\Go',
'C:\Program Files\Node.js',
'C:\Program Files\Ruby',
'C:\Program Files\Java',
'C:\Program Files\Eclipse Adoptium'
)
foreach ($path in $paths) {
if (Test-Path $path) {
Write-Host "Removing $path ..."
Remove-Item -Recurse -Force $path -ErrorAction SilentlyContinue
}
}
docker system prune -a -f
Write-Host "Disk space after cleanup:"
Get-PSDrive C | Select-Object Used, Free | Format-Table

# Build Docker images
- name: Build webkitdev/base
run: docker build --tag webkitdev/base:${{ matrix.tag }} --file base/Dockerfile.${{ matrix.tag }} base
- name: Build webkitdev/scripts
run: docker build --tag webkitdev/scripts:${{ matrix.tag }} --build-arg IMAGE_TAG=${{ matrix.tag }} scripts
- name: Build webkitdev/scm
run: docker build --tag webkitdev/scm:${{ matrix.tag }} --build-arg IMAGE_TAG=${{ matrix.tag }} scm
run: docker build --tag webkitdev/scm:${{ matrix.tag }} --build-arg IMAGE_TAG=${{ matrix.tag }} scm
- name: Build webkitdev/tools
run: docker build --tag webkitdev/tools:${{ matrix.tag }} --build-arg IMAGE_TAG=${{ matrix.tag }} tools
- name: Build webkitdev/msbuild-2022
Expand All @@ -38,7 +73,7 @@ jobs:
- name: Verify webkitdev/buildbot-worker
run: docker run --rm webkitdev/buildbot-worker:${{ matrix.tag }} cmake --system-information

# Publish Docker images
# Publish Docker images to DockerHub
- name: Dockerhub login
if: github.ref_name == github.event.repository.default_branch
uses: docker/login-action@v3
Expand Down
13 changes: 7 additions & 6 deletions BUILDBOT.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ The `docker-webkit-dev` project contains Docker images for running Buildbot
workers that connect to WebKit infrastructure. The Windows WebKit port builds
happen within Docker containers running the `webkitdev/buildbot-worker` image.

> [!IMPORTANT]
> [!IMPORTANT]
> To connect to WebKit infrastructure credentials are required.
> Contact the infrastructure team on [Slack](https://webkit.slack.com) by
> dropping a message in the `#dev` channel for assistance in connecting new
Expand All @@ -18,9 +18,10 @@ compatibility see the

| Tag Name | Automated | Description |
|---|:---:|---|
| 2022 | :white_check_mark: | A Windows 2022 server container |
| 2022 | :white_check_mark: | A Windows Server 2022 container |
| windows-2022 | :x: | A Windows container, used for Layout Tests |
| 1809 | :x: | A Windows 2019 server container |
| 2025 | :white_check_mark: | A Windows Server 2025 container |
| windows-2025 | :x: | A Windows container, used for Layout Tests |

Visit [Docker Hub](https://hub.docker.com/r/webkitdev/buildbot-worker/tags) to
see when the last build happened for the image's tags.
Expand All @@ -39,7 +40,7 @@ for more details.
| BUILD_WORKER_NAME | :white_check_mark: | Name for the worker, provided by infrastructure team |
| BUILD_WORKER_PASSWORD | :white_check_mark: | Password for the worker, provided by infrastructure team |
| BUILD_WORKER_KEEPALIVE | :x: | Time in seconds that messages should be sent by the worker to the server, defaults to 240 |
| ADMIN_NAME | :x:| Contact name for the admin of the worker |
| ADMIN_NAME | :x:| Contact name for the admin of the worker |
| ADMIN_EMAIL | :x: | Contact e-mail address for the admin of the worker |
| HOST_DESCRIPTION |:x: | A description of the host running the worker |
| COMPILER | :white_check_mark: | Needs to be set to `Clang` since the alternative, `cl`, is no longer able to build WebKit |
Expand All @@ -60,8 +61,8 @@ COMPILER=Clang
```

## Running the Buildbot worker
On a Windows Server 2022 machine run the following in a powershell session. On
Windows Server 2022 the Docker container runs in process isolation mode which
On a Windows Server 2022/2025 machine run the following in a powershell session.
On Windows Server 2022/2025 the Docker container runs in process isolation mode which
gives it access to all the resources of the host.

> [!NOTE]
Expand Down
2 changes: 1 addition & 1 deletion Build-All.ps1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
param(
[Parameter(Mandatory)]
[ValidateSet('1809','2022','aws','windows-1809','windows-aws','windows-2022')]
[ValidateSet('2022','windows-2022','2025','windows-2025')]
[string]$tag
)

Expand Down
2 changes: 1 addition & 1 deletion Publish-All.ps1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
param(
[Parameter(Mandatory)]
[ValidateSet('1809','2022','aws','windows-1809','windows-aws','windows-2022')]
[ValidateSet('2022','windows-2022','2025','windows-2025')]
[string]$tag
)

Expand Down
38 changes: 18 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ Docker images for local WebKit development and CI/CD on Windows.

## Host Setup
Using the `webkitdev` Docker images requires a Windows host, ideally Windows 11
or Windows Server 2022 but Windows 10 and Windows Server 2019 can also be used,
with [Docker](https://www.docker.com/) installed and targeting Windows
containers. For new installs follow the latest documentation to setup
or Windows Server 2022/2025, with [Docker](https://www.docker.com/) installed
and targeting Windows containers. For new installs follow the latest
documentation to setup
[Windows for containers](https://learn.microsoft.com/en-us/virtualization/windowscontainers/quick-start/set-up-environment).

## Images
Expand All @@ -29,26 +29,24 @@ WebKit infrastructure.
| [buildbot-worker](https://hub.docker.com/r/webkitdev/buildbot-worker) | Contains Buildbot and scripts to connect to WebKit CI/CD infrastructure |

Docker images support tagging. For Windows images the tag references the version
of the container base image, Windows Server 2022 and Windows Server 2019.
Compatibility depends on what the host OS is. In general Windows 11 needs to
target 2022 tags and Windows 10 needs to target 2019 tags. For the latest
information on Windows container version compatibility see the
of the container base image. Compatibility depends on what the host OS is. For
the latest information on Windows container version compatibility see the
[documentation](https://learn.microsoft.com/en-us/virtualization/windowscontainers/deploy-containers/version-compatibility).

| Tag | Automated | Win 11 | Win 10 | Description |
|---|:---:|:---:|:---:|---|
| 2022 | :white_check_mark: | :white_check_mark: | :x: | A Windows 2022 server container |
| windows-2022 | :x: | :white_check_mark: | :x: | A Windows container, used for Layout Tests |
| 1809 | :x: | :white_check_mark: | :white_check_mark: | A Windows 2019 server container |
| windows-1809 | :x: | :white_check_mark: | :white_check_mark: | A Windows container, used for Layout Tests |
| Tag | Automated | Description |
|---|:---:|---|
| 2022 | :white_check_mark: | A Windows Server 2022 container |
| windows-2022 | :x: | A Windows container, used for Layout Tests |
| 2025 | :white_check_mark: | A Windows Server 2025 container |
| windows-2025 | :x: | A Windows container, used for Layout Tests |

The `windows-<version>` have a larger base image containing more Windows OS
components making them ideal for testing WebKit. The other tags use Windows
Server Core and are suitable for building WebKit.

### Building locally
> [!IMPORTANT]
> Windows 11 and Windows Server 2022 users should pull the images directly from
> Windows 11 and Windows Server 2022/2025 users should pull the images directly from
> DockerHub rather than building locally. The only exception is when
> [updating the images](UPDATING.md).

Expand All @@ -61,7 +59,7 @@ and tagged. The created time should be within the time frame the script was
executing in.

## Building the Windows WebKit port
With the `webkitdev/msbuild-2022` image everything is there to do a build of
With the `webkitdev/msbuild-2022` image everything is there to do a build of
the Windows WebKit port. Start out by doing a local checkout of the
[WebKit repository](https://github.com/WebKit/WebKit). The `docker run` command
needs to be populated with the following fields.
Expand All @@ -70,7 +68,7 @@ needs to be populated with the following fields.
|---|---|
| tag | The tag to use |
| cpu-count | The number of CPUs to dedicate to the container (optional on a Windows Server host) |
| [memory](https://docs.docker.com/reference/cli/docker/container/run/#memory) | The memory limit for the container (optional on a Windows Server host) |
| [memory](https://docs.docker.com/reference/cli/docker/container/run/#memory) | The memory limit for the container (optional on a Windows Server host) |
| [volume](https://docs.docker.com/reference/cli/docker/container/run/#volume) | A local path containing the WebKit checkout, use `/` over `\` |

```powershell
Expand All @@ -88,7 +86,7 @@ like this :point_down:.
docker run --name build --rm -it `
--cpu-count=6 --memory=16g `
--volume C:/GitHub/webkit:C:/webkit `
webkitdev/msbuild-2022:2022 powershell
webkitdev/msbuild-2022:2025 powershell
```

Once the command is run it will place you into a Powershell session. From there
Expand All @@ -103,9 +101,9 @@ perl Tools\Scripts\build-webkit
```

> [!NOTE]
> Building in a container in Hyper-V isolation, the default for Windows 11 and
> 10, will take longer than a local build. Building in a container in process
> mode, the default for Windows Server 2022 and 2019, will build in a similar
> Building in a container in Hyper-V isolation, the default for Windows 11,
> will take longer than a local build. Building in a container in process
> mode, the default for Windows Server 2022 and 2025, will build in a similar
> time as a local build.
>
> Ideally dedicate a large amount of resources when running in Hyper-V to reduce
Expand Down
2 changes: 1 addition & 1 deletion UPDATING.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Use the `Build-All.ps1` PowerShell script to build the images. Again it expects
a single argument `-Tag` which specifies the tag to build.

```powershell
./Build-All -tag 2022
./Build-All -tag 2025
```

Executing the script will create all the `webkitdev` images. Most of `RUN`
Expand Down
1 change: 0 additions & 1 deletion base/Dockerfile.1809

This file was deleted.

1 change: 1 addition & 0 deletions base/Dockerfile.2025
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
FROM mcr.microsoft.com/dotnet/framework/runtime:4.8.1-windowsservercore-ltsc2025@sha256:fdb22792bfb201f78ba84c54dc76e9f062bb811b9441bfc5c70ec6dd9b5c4c95
1 change: 0 additions & 1 deletion base/Dockerfile.aws

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/windows:1809@sha256:5dc542418c860e622a8da5d2db2dd3f3eb1212c104857ca947dac2fd171a26b5
FROM mcr.microsoft.com/windows/server:ltsc2025@sha256:bfb0496d2ff297e49b581ea16166ec955d4afbe94a412ad99db52ce554fb327c

SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

Expand Down
6 changes: 0 additions & 6 deletions base/Dockerfile.windows-aws

This file was deleted.

8 changes: 4 additions & 4 deletions base/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/base:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/base:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/base:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/base:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 2022
version: 2025
8 changes: 4 additions & 4 deletions buildbot-worker/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/buildbot-worker{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/buildbot-worker{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/buildbot-worker{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/buildbot-worker{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 2022
version: 2025
8 changes: 4 additions & 4 deletions msbuild-2022/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/msbuild-2022:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/msbuild-2022:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/msbuild-2022:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/msbuild-2022:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 2022
version: 2025
2 changes: 0 additions & 2 deletions renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
"enabledManagers": ["dockerfile"],
"dockerfile": {
"ignorePaths": [
"base/Dockerfile.aws",
"base/Dockerfile.windows-aws",
"scripts/",
"scm/",
"tools/",
Expand Down
8 changes: 4 additions & 4 deletions scm/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/scm:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/scm:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/scm:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/scm:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 2022
version: 2025
8 changes: 4 additions & 4 deletions scripts/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/scripts:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/scripts:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/scripts:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/scripts:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 20H2
version: 2025
8 changes: 4 additions & 4 deletions tools/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ tags:
{{/if}}
manifests:
-
image: webkitdev/tools:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}1809
image: webkitdev/tools:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
platform:
architecture: amd64
os: windows
version: 1809
version: 2022
-
image: webkitdev/tools:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2022
image: webkitdev/tools:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}2025
platform:
architecture: amd64
os: windows
version: 2022
version: 2025
Loading