Commit Graph
38 Commits
Author SHA1 Message Date
J Logan e29657b86e Pin macOS CI builds to Swift 6.3 for now. (#771)
- CI runners moved to the Xcode developer beta as the default, but macOS
builds are failing with a conflicting options error for
`-warnings-as-errors` and `-suppress-warnings`.
2026-06-16 11:44:27 -04:00
Kathryn Baldauf 1437c67f5a Update github actions to use SHA versions (#763)
Related to https://github.com/apple/container/pull/1649. This PR updates
the GitHub workflows to ensure all imported actions are referenced by
commit SHA.

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2026-06-04 15:08:22 -07:00
Danny Canter 9275f365dd [Experimental] Add Sandboxy binary (#607)
Sandboxy is an example tool to run isolated coding agents.
2026-06-03 12:27:49 -04:00
Danny Canter 0f4c8cf592 Make unit tests runnable on Linux (#686)
Closes #606

This lets the unit tests be runnable on linux. The change:

- Adds a linux-test makefile target so we can run the unit tests locally
- Fixes up some test code to work on Linux (mostly ifdefs)
- Runs the unit tests in CI now
2026-04-15 16:58:03 -07:00
Danny Canter 6f7e7f98ba makefile: Add goal to build the project in a linux container (#674)
Today our CI builds all of the linux code we have with musl and libc to
ensure everything is silky smooth. We should have a way to do the same
locally. This adds a new macOS only goal that spins up a container
(requires `container` to be installed) that builds an image with our
deps (libarchive and compression libs) and then builds the project. It
supports supplying whatever libc (musl or glibc) to verify they both
work.
2026-04-09 12:19:34 -07:00
Danny Canter 997d5a4b08 Actions: Add Linux build step (#654)
Related to https://github.com/apple/containerization/issues/606

To make sure the project (and many linux specific libraries) builds on
linux lets add a linux step to build for both musl and glibc. Eventually
this will run unit tests as well. This change needs a bit more libc
agnostic-ifying work to make sure things work for both libcs.
2026-04-07 15:13:12 -07:00
Dmitry Kovba 7da377974b Use the actual path to Swiftly on GitHub runners (#595)
Use the actual path to Swiftly on GitHub runners instead of a link.
2026-03-24 16:49:59 -07:00
J Logan f1195fead5 GH actions: do not interpolate template variables in run blocks. (#567) 2026-03-02 12:04:36 -08:00
Danny Canter c1183767cb CI: Add signed commits check (#530)
We should fail CI if commits aren't signed so it's more obvious to
contributors.
2026-02-13 12:47:32 -08:00
J Logan d40650f1fb Update workflow label to select macOS 26 builder. (#485) 2026-01-21 00:38:54 -08:00
Danny Canter fb95398fb5 ci: Build for release (#465) 2026-01-01 17:40:30 -08:00
Danny Canter cbb48bc0fd vminitd: Strip binaries (#464) 2026-01-01 17:07:14 -08:00
Salman Chishti 57d6e0b499 Upgrade GitHub Actions to latest versions (#451)
## Summary

Upgrade GitHub Actions to their latest versions for improved features,
bug fixes, and security updates.

## Changes

| Action | Old Version(s) | New Version | Release | Files |
|--------|---------------|-------------|---------|-------|
| `actions/upload-pages-artifact` |
[`v3`](https://github.com/actions/upload-pages-artifact/releases/tag/v3)
|
[`v4`](https://github.com/actions/upload-pages-artifact/releases/tag/v4)
|
[Release](https://github.com/actions/upload-pages-artifact/releases/tag/v4)
| containerization-build-template.yml |

## Why upgrade?

Keeping GitHub Actions up to date ensures:
- **Security**: Latest security patches and fixes
- **Features**: Access to new functionality and improvements
- **Compatibility**: Better support for current GitHub features
- **Performance**: Optimizations and efficiency improvements

### Security Note

Actions that were previously pinned to commit SHAs remain pinned to SHAs
(updated to the latest release SHA) to maintain the security benefits of
immutable references.

### Testing

These changes only affect CI/CD workflow configurations and should not
impact application functionality. The workflows should be tested by
running them on a branch before merging.
2025-12-16 23:19:18 -08:00
Salman Chishti d6109d70cf Upgrade GitHub Actions for Node 24 compatibility (#452)
## Summary

Upgrade GitHub Actions to their latest versions to ensure compatibility
with Node 24, as Node 20 will reach end-of-life in April 2026.

## Changes

| Action | New Version | Release |
|--------|-------------|---------|
| `actions/checkout` |
[`8e8c483`](https://github.com/actions/checkout/commit/8e8c483db84b4bee98b60c0593521ed34d9990e8)
(v6) | [Release](https://github.com/actions/checkout/releases/tag/v6) |
| `actions/upload-artifact` |
[`b7c566a`](https://github.com/actions/upload-artifact/commit/b7c566a772e6b6bfb58ed0dc250532a479d7789f)
(v6) |
[Release](https://github.com/actions/upload-artifact/releases/tag/v6) |
| `actions/download-artifact` |
[`37930b1`](https://github.com/actions/download-artifact/commit/37930b1c2abaa49bbe596cd826c3c89aef350131)
(v7) |
[Release](https://github.com/actions/download-artifact/releases/tag/v7)
|

## Context

Per [GitHub's
announcement](https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/),
Node 20 is being deprecated and runners will begin using Node 24 by
default starting March 4th, 2026.

### Why this matters

- **Node 20 EOL**: April 2026
- **Node 24 default**: March 4th, 2026
- **Action**: Update to latest action versions that support Node 24

### Security Note

All actions are pinned to commit SHAs for security, with version tags
noted in comments for reference.

### Testing

These changes only affect CI/CD workflow configurations and should not
impact application functionality.
2025-12-16 23:18:58 -08:00
Melissa Kilby 26dcd68340 chore: restrict GitHub workflow permissions - future-proof (#339)
See https://github.com/swiftlang/github-workflows/issues/167 for
additional context

This approach aligns with security best practices, as detailed in the
following documentation:

-
https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
-
https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#defining-access-for-the-github_token-scopes
-
https://openssf.org/blog/2024/08/12/mitigating-attack-vectors-in-github-workflows/


The default GITHUB_TOKEN permissions are defined at the repository
level. This PR modifies the workflow-level overrides to conform to
OpenSSF best practices -> defense in depth.

Allow me to quote OpenSSF:

https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

> The highest score is awarded when the permissions definitions in each
workflow's yaml file are set as read-only at the top level and the
required write permissions are declared at the run-level.”

> Remediation steps
> - Set top-level permissions as read-all or contents: read as described
in GitHub's documentation.
> - Set any required write permissions at the job-level. Only set the
permissions required for that job; do not set permissions: write-all at
the job level.


Compare to the LLVM project:

Top-level: contents read, e.g.
https://github.com/swiftlang/llvm-project/blob/next/.github/workflows/build-ci-container-windows.yml#L3-L4
-> this makes it future-proof

Job-level: Allow write permissions as needed, e.g.
https://github.com/swiftlang/llvm-project/blob/next/.github/workflows/build-ci-container-windows.yml#L53-L58

Signed-off-by: Melissa Kilby <mkilby@apple.com>
2025-10-17 15:00:03 -07:00
Dmitry Kovba b331d29959 Update an issue template (#304)
This PR adds the default value "N/A" to the logs section to prevent it
from being empty in most issues.
2025-10-01 11:24:31 -04:00
Kathryn Baldauf 41c3e4a2c3 Update xcode developer dir to new regularly updated symlink (#234)
The Xcode installation on the runners is regularly updated to the latest
release. A symlink at /Applications/Xcode-latest.app points to the most
recent installation. We should not rely on a specific version path.

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-07-25 11:38:55 -07:00
Dmitry Kovba 382c73ae78 Use a consistent capitalization in a bug report template (#181) 2025-06-27 15:51:47 -07:00
Kathryn Baldauf 73097b795c Remove use of triage label (#180)
Tags on the repo should be a way to classify an item instead of denoting
workflow or status of the item. Remove the addition of the triage label
on bug and feature issues.

Related to https://github.com/apple/container/pull/262

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-27 14:08:01 -04:00
Kathryn Baldauf 958a83b23b Switch to using issue types for bugs and features (#170)
Matches https://github.com/apple/container/pull/258

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-25 17:09:53 -07:00
Dmitry Kovba 4bacf4c578 Remove the support for CURRENT_SDK (#164)
This PR removes the no longer needed support for `CURRENT_SDK`.
2025-06-25 12:30:06 -04:00
Satyam Singh 22f2efd8d1 fix: correct release condition in GitHub Actions and globalize enviro… (#127)
# Refactor GitHub Actions Workflow: Containerization Build
## 🛠 Summary
This PR introduces several important improvements and cleanups to the
build-containerization-template GitHub Actions workflow for better
maintainability, correctness, and readability.

### 🔧 Changes Made
#### 1. ✅ Fix invalid conditional syntax
- **!= is not supported in expressions** with **if**: in GitHub Actions.

- Only logical operators like !, &&, || are valid.

#### 2. ✅ Globalized environment variables
- Moved CURRENT_SDK and DEVELOPER_DIR to the job-level env: block to:

- Avoid redundancy across steps

- Make the workflow more maintainable

### 3. ✅ Replaced `secrets.GITHUB_TOKEN` with `github.token`
- Prefer github.token for GitHub-provided auth token to improve clarity
and scoping.

@katiewasnothere
2025-06-23 09:26:50 -07:00
Joseph Heck 445450dcce limits buildAndTest to Apple repository (#150)
Constrains the buildAndTest job to only run on the
`apple/containerization` repository due to Runner constraints.

Simplest solution - fixes #132
2025-06-17 14:20:20 -07:00
Dmitry Kovba a3cb1f0103 Update to Swift 6.2 and Swift 6.2-snapshot in vminitd (#94)
This PR resolves https://github.com/apple/containerization/issues/58 and
https://github.com/apple/containerization/issues/119. Requires updating
Swift and Static Linux SDK on GitHub runners. Please also see
https://github.com/apple/container/pull/195.
2025-06-13 17:46:30 -07:00
Kathryn Baldauf 4751d073bb Improve release tag regex (#122)
Matches changes made in https://github.com/apple/container/pull/187 by
@Thedarkmatter10

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-13 14:45:16 -07:00
Dmitry Kovba 256daaf481 Update issue templates (#114)
Please see commits for the list of changes.
2025-06-13 09:10:43 -07:00
Kathryn Baldauf 6d9e4b9c4d Add issue template for containerization (#102)
Matches templates made in container here
https://github.com/apple/container/pull/152.

Points questions to the container Discussions.

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-12 15:18:06 -04:00
Satyam Singh 5240d36464 fix: quote inputs and improve shell conditionals for safety (#68)
This PR improves **safety and consistency** of the GitHub Actions
workflow (build-test-images.yml) file by:
  - Using **[[ ... ]]** **instea**d of **[ ... ]** for conditionals.
- Adding **double quotes** around inputs and refs to **avoid**
evaluation issues.

This helps prevent bugs in **shell parsing**, especially with **empty or
misinterpreted** input values.


@katiewasnothere @wlan0
2025-06-10 13:54:48 -07:00
Kathryn Baldauf 2923b33836 Allow building docs from main (#53)
We eventually only want to support building docs from release branches
and tags, however, while we're working to initially set up the docs, we
may have some churn. So we want to be able to publish from main during
that churn.

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-09 16:40:22 -07:00
Kathryn Baldauf 0338c07283 Only allow docs publish on tags or release branches (#32)
Matches same changes on container
https://github.com/apple/container/pull/30

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-08 10:12:38 -07:00
Michael Crosby 9959810656 separate fetch-default-kernel make target (#27)
Signed-off-by: michael crosby <michael_crosby@apple.com>
2025-06-06 15:05:24 -07:00
Kathryn Baldauf 46260fd6a6 Move permissions in release and add id-token (#24)
Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 20:28:08 -07:00
Kathryn Baldauf 8ecbd124e3 Fix refs parsing in gh action (#20)
Remove erroneous quotes when checking for wildcard match in GitHub
action

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:16:22 -07:00
Kathryn Baldauf 816a959ada Add id token for deploying docs (#18)
Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:16:21 -07:00
Kathryn Baldauf 5624a8397e Add branch protection to the test image build pipeline (#15)
This adds branch protection to the workflow for building container test
images. This PR additionally moves the permissions for docs deploying to
be job level.

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:16:19 -07:00
Kathryn Baldauf 8d880efc36 Remove extra source tar from release (#13)
A release is made by default with sources in a tar and zip (example
[here](https://github.com/apple/containerization/releases/tag/untagged-a4e930d3152ef58348f1))
so we can remove this extra tar

Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:16:17 -07:00
Kathryn Baldauf 502dab6108 Update containerization apple main (#4)
Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:15:44 -07:00
Kathryn Baldauf 6bc739a670 Add github actions workflows (#1)
Signed-off-by: Kathryn Baldauf <k_baldauf@apple.com>
2025-06-05 16:15:28 -07:00