swiftlang / swift-docker

Docker Official Image packaging for Swift
https://swift.org
Apache License 2.0
1.36k stars 182 forks source link

Swift 5.7 Ubuntu 22.04 jammy container #307

Closed freef4ll closed 2 years ago

freef4ll commented 2 years ago

In https://github.com/apple/swift-docker/pull/301/ Ubuntu 22.04 was added for main, and currently no 5.7 nightly release exists for jammy that is published in Docker registry

5.6 deb packages do have jammy support - https://archive.swiftlang.xyz/repos/ubuntu/pool/main/s/swiftlang/, will container images with Swift 5.7 be published for jammy, like they're for nightly-5.7-focal?

$  docker run -ti swiftlang/swift:nightly-main-jammy swift --version
Swift version 5.8-dev (LLVM e41a0a126d143ae, Swift 23e5143d22cb768)
Target: x86_64-unknown-linux-gnu

$ docker run -ti swiftlang/swift:nightly-jammy swift --version
Swift version 5.8-dev (LLVM e41a0a126d143ae, Swift 23e5143d22cb768)
Target: x86_64-unknown-linux-gnu
tomerd commented 2 years ago

@freef4ll would you like to create a PR to add the docker files required to support this? should follow the example of the 20.04 ones

shahmishal commented 2 years ago

@tomerd We currently don't build toolchain for Ubuntu 22.04 for Swift 5.7.

shahmishal commented 2 years ago

I will try to setup nightly toolchain for 22.04

freef4ll commented 2 years ago

@tomerd, I opened https://github.com/apple/swift-docker/pull/308, but it won't work until Swift is built for this platform and https://download.swift.org/swift-5.7-branch/ubuntu2204/latest-build.yml becomes populated.

0xTim commented 2 years ago

Just to add to this - as of a few weeks ago Heroku made Ubuntu 22.04 their default stacks. Anyone running apps on Heroku not using Ubuntu 22 now get a warning saying they should upgrade. This obviously presents a problem for anyone running Swift on Heroku as if they're not aware they'll upgrade and be unable to run their apps. (The current Heroku build pack will still attempt to install Swift 5.6 but obviously fails). So getting 5.7 on Ubuntu 22.04 would be great!

gohanlon commented 2 years ago

My app is on Swift 5.6 and needed Jammy, too (for non-Swift reasons). I'd love to replace the naive Swift 5.6 Jammy images I cobbled together. My app will move to Swift 5.7 as soon as it's released.

shahmishal commented 2 years ago

CI job configured: https://ci.swift.org/job/oss-swift-5.7-package-ubuntu-22_04/ https://ci.swift.org/view/Swift%205.7/job/oss-swift-5.7-package-ubuntu-22_04-aarch64/

shahmishal commented 2 years ago

Few tests are failing on Ubuntu 22.04, here is one fix https://github.com/apple/swift/pull/60408

shahmishal commented 2 years ago

Current Test failures:

Failed Tests (11):
  Swift(linux-aarch64) :: Driver/filelists.swift
  Swift(linux-aarch64) :: Misc/stats_dir.swift
  Swift(linux-aarch64) :: SourceKit/Misc/match-module-cache-with-compiler.swift
  Swift-validation(linux-aarch64) :: BuildSystem/android_cross_compile.test
  Swift-validation(linux-aarch64) :: BuildSystem/llvm-targets-options.test
  Swift-validation(linux-aarch64) :: BuildSystem/skip_clean_corelibs.test
  Swift-validation(linux-aarch64) :: BuildSystem/skip_clean_llbuild.test
  Swift-validation(linux-aarch64) :: BuildSystem/skip_cmark_swift_llvm.test
  Swift-validation(linux-aarch64) :: BuildSystem/test_early_swift_driver_and_test.test
  Swift-validation(linux-aarch64) :: Python/build_swift.swift
  Swift-validation(linux-aarch64) :: Python/swift_build_support.swift
shahmishal commented 2 years ago

Hopefully this will cover most of the test failure - https://github.com/apple/swift/pull/60452

shahmishal commented 2 years ago

https://github.com/apple/swift/issues/60465

shahmishal commented 2 years ago

Ubuntu 22.04 now available for Swift 5.7 nightly snapshots on swift.org