160 lines
5.7 KiB
YAML
160 lines
5.7 KiB
YAML
persistent_worker:
|
|
labels:
|
|
name: dev-mini
|
|
resources:
|
|
tart-vms: 1
|
|
|
|
env:
|
|
TART_REGISTRY_HOSTNAME: ghcr.io
|
|
TART_REGISTRY_USERNAME: fkorotkov # GitHub supports only PATs
|
|
TART_REGISTRY_PASSWORD: ENCRYPTED[!82ed873afdf627284305afef4958c85a8f73127b09978a9786ac521559630ea6c9a5ab6e7f8315abf9ead09b6eff6eae!]
|
|
AWS_ACCESS_KEY_ID: ENCRYPTED[c187b670a17eead88c1698849376273991d09678efe37ae2f0c9738c27a2422741a71c501ef4b6a4df7bff3eca5213a9]
|
|
AWS_SECRET_ACCESS_KEY: ENCRYPTED[e456254a53b82e3167f2da23e24c389620cb3f7d47e4e5e7d993813bf9bb18c784d5cb8d88d19632073acc9e1f6096c9]
|
|
|
|
defaults: &defaults
|
|
timeout_in: 3h
|
|
update_script:
|
|
- brew update || true
|
|
- brew upgrade || true
|
|
info_script:
|
|
- tart --version
|
|
- packer --version
|
|
|
|
task:
|
|
name: "Update Vanilla Sonoma Image"
|
|
only_if: $CIRRUS_BRANCH == $CIRRUS_DEFAULT_BRANCH && changesInclude("templates/vanilla-sonoma.pkr.hcl")
|
|
<<: *defaults
|
|
build_script:
|
|
- packer init templates/vanilla-sonoma.pkr.hcl
|
|
- packer build templates/vanilla-sonoma.pkr.hcl
|
|
disable_sip_script:
|
|
- packer build -var vm_name=sonoma-vanilla templates/disable-sip.pkr.hcl
|
|
push_script:
|
|
- tart push sonoma-vanilla ghcr.io/cirruslabs/macos-sonoma-vanilla:latest ghcr.io/cirruslabs/macos-sonoma-vanilla:14.6.1
|
|
always:
|
|
cleanup_script:
|
|
- tart delete sonoma-vanilla
|
|
|
|
task:
|
|
name: "Update Vanilla Sequoia Image"
|
|
only_if: $CIRRUS_BRANCH == $CIRRUS_DEFAULT_BRANCH && changesInclude("templates/vanilla-sequoia.pkr.hcl")
|
|
<<: *defaults
|
|
build_script:
|
|
- packer init templates/vanilla-sequoia.pkr.hcl
|
|
- packer build templates/vanilla-sequoia.pkr.hcl
|
|
disable_sip_script:
|
|
- packer build -var vm_name=sequoia-vanilla templates/disable-sip.pkr.hcl
|
|
push_script:
|
|
- tart push sequoia-vanilla ghcr.io/cirruslabs/macos-sequoia-vanilla:latest ghcr.io/cirruslabs/macos-sequoia-vanilla:15.0-rc
|
|
always:
|
|
cleanup_script:
|
|
- tart delete sequoia-vanilla
|
|
|
|
task:
|
|
name: "Update Vanilla Sequoia Beta Image"
|
|
only_if: $CIRRUS_BRANCH == $CIRRUS_DEFAULT_BRANCH && changesInclude("templates/vanilla-sequoia-beta.pkr.hcl")
|
|
<<: *defaults
|
|
build_script:
|
|
- packer init templates/vanilla-sequoia-beta.pkr.hcl
|
|
- packer build templates/vanilla-sequoia-beta.pkr.hcl
|
|
disable_sip_script:
|
|
- packer build -var vm_name=sequoia-vanilla templates/disable-sip.pkr.hcl
|
|
push_script:
|
|
- tart push sequoia-vanilla ghcr.io/cirruslabs/macos-sequoia-vanilla:15.1-beta-3
|
|
always:
|
|
cleanup_script:
|
|
- tart delete sequoia-vanilla
|
|
|
|
task:
|
|
name: "Update Base Images ($MACOS_VERSION)"
|
|
alias: update-base
|
|
matrix:
|
|
- env:
|
|
MACOS_VERSION: sonoma
|
|
only_if: $CIRRUS_CRON == "monthly"
|
|
<<: *defaults
|
|
pull_vanilla_script:
|
|
- tart pull ghcr.io/cirruslabs/macos-$MACOS_VERSION-vanilla:latest
|
|
build_base_script:
|
|
- packer init templates/base.pkr.hcl
|
|
- packer build -var macos_version="$MACOS_VERSION" templates/base.pkr.hcl
|
|
push_base_script:
|
|
- tart push $MACOS_VERSION-base ghcr.io/cirruslabs/macos-$MACOS_VERSION-base:latest
|
|
always:
|
|
cleanup_script:
|
|
- tart delete $MACOS_VERSION-base
|
|
|
|
task:
|
|
name: "Update Xcode Images ($MACOS_VERSION $XCODE_VERSION)"
|
|
depends_on: update-base
|
|
only_if: $CIRRUS_CRON == "monthly" # Every first Saturday of a month at 14 UTC
|
|
env:
|
|
matrix:
|
|
- MACOS_VERSION: sonoma
|
|
XCODE_VERSION: 15.4
|
|
LATEST: true
|
|
- MACOS_VERSION: sonoma
|
|
XCODE_VERSION: 15.3
|
|
- MACOS_VERSION: sonoma
|
|
XCODE_VERSION: 15.2
|
|
- MACOS_VERSION: sonoma
|
|
XCODE_VERSION: 16
|
|
<<: *defaults
|
|
pull_base_script:
|
|
- tart pull ghcr.io/cirruslabs/macos-$MACOS_VERSION-base:latest
|
|
build_xcode_script:
|
|
- packer init templates/xcode.pkr.hcl
|
|
- packer build -var macos_version="$MACOS_VERSION" -var xcode_version="[\"$XCODE_VERSION\"]" templates/xcode.pkr.hcl
|
|
push_script: |
|
|
if [[ -z "$LATEST" ]]
|
|
then
|
|
tart push "$MACOS_VERSION-xcode:$XCODE_VERSION" ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:$XCODE_VERSION
|
|
else
|
|
tart push "$MACOS_VERSION-xcode:$XCODE_VERSION" ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:$XCODE_VERSION ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:latest
|
|
fi
|
|
always:
|
|
cleanup_script:
|
|
- tart delete "$MACOS_VERSION-xcode:$XCODE_VERSION"
|
|
|
|
task:
|
|
name: "Update Runner Image ($MACOS_VERSION)"
|
|
env:
|
|
matrix:
|
|
- MACOS_VERSION: sonoma
|
|
XCODE_VERSIONS: 16,15.2,15.3,15.4
|
|
only_if: $CIRRUS_CRON == "weekly" # Every Sunday at 14 UTC
|
|
<<: *defaults
|
|
pull_base_script:
|
|
- tart pull ghcr.io/cirruslabs/macos-$MACOS_VERSION-base:latest
|
|
build_xcode_script:
|
|
- packer init templates/xcode.pkr.hcl
|
|
- packer build -var tag=runner -var disk_size=300 -var disk_free_mb=100000 -var macos_version="$MACOS_VERSION" -var xcode_version="[$XCODE_VERSIONS]" templates/xcode.pkr.hcl
|
|
push_script: |
|
|
tart push "$MACOS_VERSION-xcode:runner" ghcr.io/cirruslabs/macos-runner:$MACOS_VERSION
|
|
always:
|
|
cleanup_script:
|
|
- tart delete "$MACOS_VERSION-xcode:runner"
|
|
|
|
task:
|
|
name: "Release Xcode $CIRRUS_TAG ($MACOS_VERSION)"
|
|
only_if: $CIRRUS_TAG != ""
|
|
matrix:
|
|
- env:
|
|
MACOS_VERSION: sonoma
|
|
<<: *defaults
|
|
pull_base_script:
|
|
- tart pull ghcr.io/cirruslabs/macos-$MACOS_VERSION-base:latest
|
|
build_script:
|
|
- packer init templates/xcode.pkr.hcl
|
|
- packer build -var macos_version="$MACOS_VERSION" -var xcode_version="[\"$CIRRUS_TAG\"]" templates/xcode.pkr.hcl
|
|
push_script: |
|
|
if [[ $CIRRUS_TAG == *"beta"* ]]
|
|
then
|
|
tart push $MACOS_VERSION-xcode:$CIRRUS_TAG ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:$CIRRUS_TAG
|
|
else
|
|
tart push $MACOS_VERSION-xcode:$CIRRUS_TAG ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:$CIRRUS_TAG ghcr.io/cirruslabs/macos-$MACOS_VERSION-xcode:latest
|
|
fi
|
|
always:
|
|
cleanup_script:
|
|
- tart delete $MACOS_VERSION-xcode:$CIRRUS_TAG || true
|