News for hackers. Stuff that matters.
Re:Container: Apple's Linux-Container Runtime by wmf on Monday June 09, 2025 @07:25PM (#44230737)
Re:Container: Apple's Linux-Container Runtime by OJFord on Monday June 09, 2025 @07:35PM (#44230823)
I disagree, they are different, and that (containerization, not container here) is the more novel/interesting one imo. It'd be nice to focus the discussion more (though at present there are many confused comments there that think they're discussing the container tool).
Re:Container: Apple's Linux-Container Runtime by n42 on Monday June 09, 2025 @08:36PM (#44231247)
Oh, like OP I didn’t see the difference. I believe the difference is:

Container is a CLI tool

Containerization is a framework

Re:Container: Apple's Linux-Container Runtime by OJFord on Monday June 09, 2025 @08:47PM (#44231305)
Yes, container is like `docker` CLI: 'I am a developer and I want to run a container'; containerization is for packaging OCI image container sidecars into Swift .apps - you could distribute your app with postgres 'built in' (but running as a container), user doesn't need to ensure it's installed and running separately or anything.
Re:Container: Apple's Linux-Container Runtime by dang on Tuesday June 10, 2025 @12:05AM (#44232377)
Whoops, I merged them but you've persuaded me to unmerge them. This will take a bit of time.

Edit: reverted!

Re:Container: Apple's Linux-Container Runtime by OJFord on Tuesday June 10, 2025 @04:51AM (#44234244)
Oh no, sorry! :)
Re:Container: Apple's Linux-Container Runtime by dang on Wednesday June 11, 2025 @02:50PM (#44250592)
On the contrary, it was helpful. Normally "containerization framework" and "container runtime" announced on the same day by the same company would obviously be the same story—but this was a rare exception and I'm glad you pointed it out!
Re:Container: Apple's Linux-Container Runtime by jzelinskie on Monday June 09, 2025 @04:43PM (#44229248)
Container runs OCI (docker) compatible by creating lightweight VMs.

This repository houses the command-line interface which is powered by containerization[0], the Swift framework wrapping Virtualization.framework to implement an OCI runtime.

[0]: https://github.com/apple/containerization

Re:Container: Apple's Linux-Container Runtime by ok_computer on Monday June 09, 2025 @07:59PM (#44231012)
I am going to show my ineptitude by admitting this, for the life of me I couldn’t get around to implement the Mac Os native way to run linux VMs and used vm-ware fusion instead. [0]

I’m glad this more accessible package is available vs docker desktop on mac os or the aforementioned, likely to be abandoned vmware non enterprise license.

[0] [apple virtualization docs](https://developer.apple.com/documentation/virtualization/cre...)

Re:Container: Apple's Linux-Container Runtime by mrpippy on Monday June 09, 2025 @11:58PM (#44232334)
VMware Fusion is a perfectly good way of running VMs, and IMO has a better and more native UI than any other solution (Parallels, UTM, etc)
Re:Container: Apple's Linux-Container Runtime by stephenr on Tuesday June 10, 2025 @01:22AM (#44232833)
This is a weird take to me.

VMWare Fusion very much feels like a cheap one-time port of VMWare Workstation to macOS. On a modern macOS it stands out very clearly with numerous elements that are reminiscent of the Aqua days: icon styles, the tabs-within-tabs structure, etc.

Fusion also has had some pretty horrific bugs related to guest networking causing indefinite hangs in the VM(s) at startup.

Parallels isn't always perfect sailing but put it this way: I have had a paid license for both (and VBox installed), for many years to build vagrant images, but when it comes to actually running a VM for purposes other than building an image, I almost exclusively turn to Parallels.

Re:Container: Apple's Linux-Container Runtime by close04 on Tuesday June 10, 2025 @07:32AM (#44235479)
> reminiscent of the Aqua days

Maybe early Aqua. We're still in the Aqua days, if you don't count yesterday's Liquid Glass announcement. :)

Re:Container: Apple's Linux-Container Runtime by cpuguy83 on Tuesday June 10, 2025 @09:31AM (#44236589)
Not on Apple Silicon it's not. In the Intel days, sure it was great.
Re:Container: Apple's Linux-Container Runtime by mickelsen on Monday June 16, 2025 @06:06PM (#44293829)
I still can run the latest ARM Fedora Workstation on Apple Silicon with Fusion, and similar distros straight from the ISO without having to tweak stuff around or having problems with 3D acceleration, unlike UTM.
Re:Container: Apple's Linux-Container Runtime by kefirlife on Tuesday June 10, 2025 @02:24AM (#44233276)
Lima makes this really straightforward and supports vz virtualization. I particularly like that you can run x86 containers through rosetta2 via those Linux VMs with nerdctl. If you want to implement it yourself of course you can, but I appreciate the work from this project so far and have used it for a couple of years.

https://lima-vm.io/

Re:Container: Apple's Linux-Container Runtime by pdimitar on Tuesday June 10, 2025 @06:19AM (#44234903)
And you also have `colima`[0] on top of it that makes working with Docker on the command-line a seamless experience.

[0] https://github.com/abiosoft/colima

Re:Container: Apple's Linux-Container Runtime by 90s_dev on Monday June 09, 2025 @10:35PM (#44231887)
How actually is Swift as a Rust alternative? Is it feasible?

The only gripe I remember with it is that all its APIs are weird.

Like instead of normal names, you have Apple-legacy-names for methods/classes.

Re:Container: Apple's Linux-Container Runtime by EPWN3D on Monday June 09, 2025 @10:41PM (#44231908)
Depends on what you're doing. If you want to write systems code, Swift is very allocation-happy and will probably not be the best fit. They're trying to make an embedded Swift, but progress is pretty slow, since that's not going to be something that gets anyone promoted.

If you just want to write A Thing, then it's up to your individual taste, what's available in the ecosystem, etc.

Re:Container: Apple's Linux-Container Runtime by dwaite on Tuesday June 10, 2025 @06:43PM (#44242320)
Apple has started using Swift for production embedded code run within the Secure Enclave. I've been looking out for any evidence whether they are using it in the C1 modem baseband.

I don't think I'd push for it over Rust for those applications, but there is apparently wood behind the arrow internally.

Re:Container: Apple's Linux-Container Runtime by tcmart14 on Tuesday June 10, 2025 @12:39AM (#44232582)
I can't speak to performance since I don't really race languages. But as far as feel and what not, it is very similar. But there is also a pretty good overlap in people who worked on Rust and people who worked in Swift. Graydon worked on both. So Swift has a lot of similarities with Rust. The way I usually word it is, Swift is like having C# with mostly everything you like about Rust.

I believe a lot of the legacy names come from when your interfacing with platform APIs like UIKit and such if you have to and they haven't quiet gotten a bump from their Objective-C APIs to have more swifty-APIs.

Re:Container: Apple's Linux-Container Runtime by written-beyond on Tuesday June 10, 2025 @01:03AM (#44232724)
Rust and Swift have done a fair bit of borrowing from each other "pun intended".

I've never got the chance to work with swift since their cross platform compatibility and "server-side swift" have been recent introductions.

In terms comparison, it really is the closest you can get to a rust that ARC BOX's everything (which has/ is planned to come down when lifetimes come in). You get a good runtime and good performance.

Re:Container: Apple's Linux-Container Runtime by waterTanuki on Tuesday June 10, 2025 @01:56AM (#44233061)
much of the new swift libraries/apis don't have the legacy "NS" prefixes you're thinking of
Re:Container: Apple's Linux-Container Runtime by rafram on Tuesday June 10, 2025 @07:11AM (#44235324)
Swift isn't quite as fast, because reference counting is inherently slower at runtime than the allocations/deallocations generated by the Rust borrow checker.

On the other hand, Swift has (IMO) a much cleaner and less symbol-heavy syntax than Rust. Easier to read and write. Less of a culture of doing crazy metaprogramming/DSL definition with macros, and the builder DSL built into the language (which SwiftUI uses) is pretty nice and generates mostly understandable compile errors.

I actually like Apple's APIs, even the legacy ones. There's some weirdness, like how some file APIs want paths and some want URIs, but it's not that bad.

Re:Container: Apple's Linux-Container Runtime by dwaite on Tuesday June 10, 2025 @06:40PM (#44242298)
They are different language designs sharing quite a few of the same features/philosophies.

Swift is good for business logic, like writing an app.

Rust is better for infrastructure, like writing a HTTP/3 server or Javascript VM.

Swift has an extremely good story about ABI stability, which makes sense when Apple ships a swift runtime and libraries as part of the OS, and needs the binaries to work across two dozen different major/minor releases.

Rust has up-front memory control primitives and options to remove the core library to cater to things like embedded systems development.

People have written apps in Rust, and Apple has written API backends and even device firmwares in Swift. I would argue both push against the ergonomics of the respective languages.

Re:Container: Apple's Linux-Container Runtime by sverhagen on Monday June 09, 2025 @11:56PM (#44232326)
Is it smart to call the implementation after the category, or am I misunderstanding what is going on? Surely they won't be able to trademark this?
Re:Container: Apple's Linux-Container Runtime by wmf on Tuesday June 10, 2025 @12:21AM (#44232464)
It's not a product; it's a command line tool that's (more or less) part of the OS. It doesn't need a fancy name.
Re:Container: Apple's Linux-Container Runtime by precompute on Tuesday June 10, 2025 @05:55AM (#44234747)
You're right, it's an incredibly pyrrhic decisions that aims to wrestle the meaning of the word towards apple's implementation. I mean, the company is named "apple". This kind of raze-a-language marketing is in their DNA.
Re:Container: Apple's Linux-Container Runtime by slroger on Wednesday June 11, 2025 @01:24AM (#44244453)
I was wondering the same thing
Re:Container: Apple's Linux-Container Runtime by yencabulator on Thursday June 12, 2025 @12:58PM (#44259976)
Apple has a track record of doing that: product names that are only unique if you keep repeating the "Apple" prefix.

Apple Card

Apple Pay

Apple Music

Apple TV

Apple Watch

App Store (trying to namesquat this is just evil, so it's "Apple App Store" for me)

Hence, I recommend you call it "Apple Container", and "Apple Containerization".

Re:Container: Apple's Linux-Container Runtime by juliendorra on Friday June 13, 2025 @12:59PM (#44270220)
Microsoft did it too with Windows and Words (supposedly after a very messy trademark dispute around excel? If I remember well?). This avoids trademark dispute on names (as you can’t trademark generic name alone) and is an effective way for very recognizable brands to extend their branding without adding too much confusion
Re:Container: Apple's Linux-Container Runtime by dang on Tuesday June 10, 2025 @12:09AM (#44232399)
Related ongoing threads:

Containerization is a Swift package for running Linux containers on macOS - https://news.ycombinator.com/item?id=44229348 - June 2025 (158 comments)

Apple announces Foundation Models and Containerization frameworks, etc - https://news.ycombinator.com/item?id=44226978 - June 2025 (346 comments)

(Normally we'd merge them but it seems there are significant if subtle differences between these)

Re:Container: Apple's Linux-Container Runtime by spockz on Tuesday June 10, 2025 @12:57AM (#44232698)
Cross posting in the right place instead of the other thread:

At first I thought this sounded like a blend of the virtualisation framework with a firecracker style lightweight kernel.

This project had its own kernel, but it also seems to be able to use the firecracker one. I wonder what the advantages are. Even smaller? Making use of some apple silicon properties?

Has anyone tried it already and is it fast? Compared to podman on Linux or Docker Desktop for Mac?

Re:Container: Apple's Linux-Container Runtime by punnerud on Tuesday June 10, 2025 @12:58AM (#44232701)
Does this enable running containers next apps to iOS and MacOS downloaded from AppStore?
Re:Container: Apple's Linux-Container Runtime by gardaani on Tuesday June 10, 2025 @01:32AM (#44232905)
I have been using lima to run Linux VMs on macOS. This new Apple tool looks very similar and I might replace lima with it.
Re:Container: Apple's Linux-Container Runtime by rcarmo on Tuesday June 10, 2025 @05:48AM (#44234696)
Not for iPadOS, alas.
Re:Container: Apple's Linux-Container Runtime by znpy on Tuesday June 10, 2025 @08:17AM (#44235873)
well of course, the ipad is not a computer (despite what the marketing says)
Re:Container: Apple's Linux-Container Runtime by zarazas on Tuesday June 10, 2025 @05:49AM (#44234699)
Will it be possible to integrate this with docker, so docker containers on Mac run more performance optimized?
Re:Container: Apple's Linux-Container Runtime by ouked on Tuesday June 10, 2025 @06:03AM (#44234801)
According to jzelinskie, yes: https://news.ycombinator.com/item?id=44229248
Re:Container: Apple's Linux-Container Runtime by dwaite on Tuesday June 10, 2025 @06:35PM (#44242260)
This is a layer on top of the operating system support for virtualization, which Docker Desktop (and tons of open source alternatives) already use.
[dead]
Re:Container: Apple's Linux-Container Runtime by stingraycharles on Tuesday June 10, 2025 @08:05AM (#44235758)
This comment doesn’t seem very substantive.

Care to elaborate why exactly this is such a bad implementation of containers?

Seems like a more secure implementation than Docker Engine, and if - as I pressure - memory management is automatic, then it will be pretty great to use.

Re:Container: Apple's Linux-Container Runtime by creshal on Tuesday June 10, 2025 @08:09AM (#44235794)
> and if - as I pressure [presume?] - memory management is automatic

Why would it be? Nothing in the Linux kernel properly supports that on a VM level (ballooning only goes in one direction, and even that only on a good day), and if Apple had managed to solve that particular Gordian knot they would've told people.

Re:Container: Apple's Linux-Container Runtime by stingraycharles on Tuesday June 10, 2025 @09:34AM (#44236629)
Isn’t memory management somewhat automatic on WSL2? Isn’t that the same problem?
Re:Container: Apple's Linux-Container Runtime by creshal on Tuesday June 10, 2025 @04:24PM (#44241082)
I've yet to see it actually work reliably, but YMMV. Either way there doesn't seem to be any indication of a similar feature attempt for Apple's runtime - since containers are meant to be restarted regularly, they might just not bother with wasting time on that feature.
Re:Container: Apple's Linux-Container Runtime by slroger on Wednesday June 11, 2025 @01:56AM (#44244588)
I just need this to get a GUI and it will be close to perfect.