swiftlang / swift-docker

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

Add Swift PATH to /etc/profile for Debian 12 #397

Closed futurejones closed 1 month ago

futurejones commented 2 months ago

CI builds for Debian 12 are consistently failing at the same point.

The issue is being caused by being unable to find the host Swift install for bootstrapping. See build logs - -- Warning: {} Host toolchain could not locate a compiler to build swift-driver.

This problem seems to be unique to Debian Docker containers being started via ssh e.g. a Jenkins pipeline build. When the container is started via ssh the saved env PATH is overwritten.

The solution is to add the PATH to /etc/profile

futurejones commented 2 months ago

@shahmishal I have run a build on Swift Community CI Server to verify the fix.

shahmishal commented 1 month ago

@swift-ci test