News for hackers. Stuff that matters.
Re:macOS in QEMU in Docker by cercatrova on Thursday June 04, 2020 @02:27PM (#23420030)
I just want a good CI/CD system for macOS to build iOS apps without needing to buy a farm of Mac Minis, or even buy a Mac, is that too much to ask?
Re:macOS in QEMU in Docker by Andrew_nenakhov on Thursday June 04, 2020 @02:39PM (#23420166)
According to Apple software license agreements, yes, it is too much to ask. You can not legally run Mac OS on non-Apple hardware.

But don't be sad, their new Mac Pro is fantastic.

Re:macOS in QEMU in Docker by benbristow on Thursday June 04, 2020 @02:43PM (#23420226)
It's also £5,499.00 in the UK (just under $7k USD).

Not exactly ideal for hobbyists.

Re:macOS in QEMU in Docker by Andrew_nenakhov on Thursday June 04, 2020 @03:11PM (#23420563)
I considered including a price tag (... and comes for only $6990 ), but decided against it for being too thick. I also think that using /s markers kinda kills the idea of sarcasm.
Re:macOS in QEMU in Docker by umvi on Thursday June 04, 2020 @03:14PM (#23420598)
Poe's law is especially strong with Apple, /s is definitely needed unless you go over the top with praising the price.
Re:macOS in QEMU in Docker by 411111111111111 on Friday June 05, 2020 @03:58AM (#23426105)
> unless you go over the top with praising the price

most apple enthusiasts think that the price is spot on and in no way overblown. (i do not have an opinion on the matter as i neither own nor use apple devices)

i dont think you can convey any point about apple in a sarcastic manner while omitting a /s tag. there are always people honestly believing the point you're stating sarcastically.

this applies to both negative and positive statements

Re:macOS in QEMU in Docker by youngtaff on Friday June 05, 2020 @04:50AM (#23426390)
I use Apple gear and think it's mostly overpriced.

I Need to buy a new MacBookPro and even though I can reclaim the VAT (sales tax) and it'll come out of corporate accounts the price makes me wince

Oh and I'd like one without a touch bar but screwed on that front unless I go high end MacBook Air

iPhone SE at £400 is pretty reasonably priced though and will be my next phone

Re:macOS in QEMU in Docker by msla on Thursday June 04, 2020 @05:41PM (#23422214)
> I also think that using /s markers kinda kills the idea of sarcasm.

Tone of voice (and tone of face) are both essential to convey sarcasm over rich channels, and both are lost over text.

Now add Poe's Law.

In short: Welcome to the wonderful world of autism! /s

Re:macOS in QEMU in Docker by zeptonix on Thursday June 04, 2020 @02:47PM (#23420269)
That's only about 7 monitor stands, could be worse /s
Re:macOS in QEMU in Docker by codemusings on Thursday June 04, 2020 @04:14PM (#23421214)
And that's before the wheels.
Re:macOS in QEMU in Docker by Andrew_nenakhov on Friday June 05, 2020 @09:07AM (#23428036)
But those wheels are the real marvel of precise engineering! You could never experience such a smooth roll before.
Re:macOS in QEMU in Docker by ChrisRR on Friday June 05, 2020 @03:55AM (#23426086)
Not exactly ideal for many people.

I've never spent more than £600 on a computer and never felt like I need to spend 10x that for any of my software development

Re:macOS in QEMU in Docker by schoolornot on Thursday June 04, 2020 @02:56PM (#23420374)
It's an unenforced provision of the license agreement. No attorneys are recommending it but it's happening. I wouldn't start your own CI firm with it though.

Unlike Microsoft, Apple has no motives to send the BSA after anyone. Pretty sure they've only used them for egregious copyright violations like the commercial Hackintoshes.

Re:macOS in QEMU in Docker by toyg on Thursday June 04, 2020 @03:22PM (#23420689)
> Apple has no motives to send the BSA after anyone

... until your virtualization layer starts having a material impact on their precious hardware sales.

You cannot build business-critical systems on contractual clauses being "unofficially unenforced".

Re:macOS in QEMU in Docker by WatchDog on Thursday June 04, 2020 @06:50PM (#23422915)
Probably the majority of macOS CI/CD use cases are materially beneficial to apple. Most people just want to automate building software for macOS/iOS. Making it easy to produce software for their products, just strengthens their ecosystem.
Re:macOS in QEMU in Docker by _bxg1 on Friday June 05, 2020 @01:19AM (#23425321)
It's almost like they should offer it themselves...
Re:macOS in QEMU in Docker by rodgerd on Thursday June 04, 2020 @07:37PM (#23423304)
Certainly Corellium are having a bad time.
Re:macOS in QEMU in Docker by user5994461 on Thursday June 04, 2020 @03:28PM (#23420739)
The EULA says you can't run Mac OS on non Apple hardware?

Pretty sure these terms are not enforceable in Europe so safe to ignore.

Re:macOS in QEMU in Docker by dahfizz on Thursday June 04, 2020 @05:53PM (#23422355)
I've always wondered why apple gets a pass on the kinds of anti competitive suits brought against google. Google gets fined Billions of dollars for preloading a web browser in Android, but it's fine for apple to completely monopolize their hardware and software ecosystems.
Re:macOS in QEMU in Docker by Leherenn on Friday June 05, 2020 @01:52AM (#23425459)
As far as I know, it's because they do not have partners.

Chromium is competing with Samsung internet and others on Android, because several companies sell Android. So it's not fine for Google to force the choice.

Apple is not competing with anyone else on iOS, you don't have a choice. As long as iOS does not have a monopoly in smartphones, they're in the clear.

Re:macOS in QEMU in Docker by dahfizz on Friday June 05, 2020 @09:59AM (#23428595)
Doesn't that seem a bit backwards? Google faces anticompetitive scrutiny because they created an open(ish) platform that others can compete on. But Apple goes all in on a walled garden where nobody even has the opportunity to compete with them. Doesn't that feel anticompetitive?

I'm certainly no friend of Google and I'm not losing sleep over them getting fined. But it seems that Apple is just as much if not more anti competitive and anti consumer, but they get a pass because of what feels like a loophole.

Re:macOS in QEMU in Docker by Leherenn on Saturday June 06, 2020 @10:53AM (#23439589)
Yeah, I don't really know, I'm not a lawyer.

At the same time, it makes kinda sense. No company with a product has to allow competition in. GM doesn't have to allow BMW motors in their cars.

When you join a market with a product, like Apple, then you don't have to allow competition in your product. When you create a market like Google did Android, then you to allow competition in that market.

I think that's the key difference, product vs market.

Re:macOS in QEMU in Docker by sjwright on Friday June 05, 2020 @02:12AM (#23425555)
If you don't respect Apple's software license terms, you have no moral authority to insist anyone respects the GPL's license terms.

I take it you'd have no objection to Google forking the Linux kernel for Android and refusing all requests for the source code.

Re:macOS in QEMU in Docker by entha_saava on Friday June 05, 2020 @11:19PM (#23436522)
Apple's software license terms are monopolistic and actively harm the industry, unlike GPL.
Re:macOS in QEMU in Docker by sjwright on Saturday June 06, 2020 @05:12AM (#23437780)
Irrelevant. Both licenses rely on exactly the same laws, morality and principles. Either you think intellectual property can be owned and licensed, or you think it should not be.
Re:macOS in QEMU in Docker by flemhans on Thursday June 04, 2020 @07:05PM (#23423033)
But how do you obtain the software in the first place?
Re:macOS in QEMU in Docker by PaulDavisThe1st on Thursday June 04, 2020 @09:09PM (#23423974)
It is freely downloadable from Apple servers.
Re:macOS in QEMU in Docker by jacobush on Thursday June 04, 2020 @07:24PM (#23423205)
Like in the 90s when people scavenged Apple ROMs. Buy old Macs, then don't use them.
Re:macOS in QEMU in Docker by 0xEFF on Thursday June 04, 2020 @03:10PM (#23420548)
Attach an Apple USB keyboard to your ESXi host and you’re good to go.
Re:macOS in QEMU in Docker by alerighi on Thursday June 04, 2020 @06:23PM (#23422691)
I'm not sure that to run a CI you have to violate the Apple license. I mean most core components of macOS (the Darwin project) are actually open source, and thus can be built and used freely. And for a CI you don't need a GUI and other stuff, only the kernel and the compiler basically. So maybe it's possible to compile a version of Darwin so close to the real macOS that has the bare minimum to run the compiler to build and test software.

Of course the problem are the SDK that you need to use to build most software, they are obviously proprietary, but does its license say that they can only be used to compile software on a real Mac?

Re:macOS in QEMU in Docker by heavyset_go on Friday June 05, 2020 @02:02AM (#23425506)
Almost none of the stuff that matters exists in the Darwin layer, though.
Re:macOS in QEMU in Docker by detaro on Thursday June 04, 2020 @06:25PM (#23422703)
Yes, the ToS for the SDKs do say that.
Re:macOS in QEMU in Docker by fulafel on Friday June 05, 2020 @02:58AM (#23425813)
You can of course run the CI/CD system on Apple hardware just fine. You can even get colo hosted Apple hardware with a monthly payment Hetzner style from a few companies.
Re:macOS in QEMU in Docker by GordonS on Friday June 05, 2020 @04:31AM (#23426289)
I used MacInCloud before Azure DevOps got hosted MacOS pipelines.

I've no affiliation with them, but can recommend them. Never had any technical issues, and the one billing issue we had was sorted out quickly by their support people.

Re:macOS in QEMU in Docker by sequence7 on Thursday June 04, 2020 @02:52PM (#23420328)
Then you should look at either Bitrise [0] who have a CI/CD system tailored to solving that exact problem or GitHub Actions [1] that provides macOS build machines.

[0] https://www.bitrise.io/

[1] https://github.com/features/actions

Re:macOS in QEMU in Docker by nine_k on Thursday June 04, 2020 @02:34PM (#23420117)
The typical answer is paying to those who do that for you, like Travis.

And yes, too much to ask. Apple's principal revenue source is selling hardware. They don't care if developing for their platform is not cheap; they explicitly target the premium segment, and are never uncomfortable with their well-known large margins.

Re:macOS in QEMU in Docker by deathanatos on Friday June 05, 2020 @01:22AM (#23425330)
Apple doesn't care if developing for their platform is a PITA.

The existence of companies like MacStadium filling rooms with Macs just to bend over backwards for inane license terms proves the paid demand is there. Apple could offer to license their OS for use not on Apple hardware — for a fee. They don't. The objection isn't to the price; the objection is that needing to manage physical hardware (as opposed to spinning up VMs like in the article) is a PITA to manage, comparatively. Companies would — and do — pay to not need to deal with that pain, but it would be a lot less painful to not need to get a third party involved / to be able to make use of the infra I have without having to stuff some Macs into a closet and wonder how I'm going to make that redundant.

Re:macOS in QEMU in Docker by GordonS on Thursday June 04, 2020 @02:39PM (#23420165)
Azure DevOps has hosted MacOS build agents, which you can use on the (generous) free tier.
Re:macOS in QEMU in Docker by benbristow on Thursday June 04, 2020 @02:44PM (#23420246)
Although it's slowly being migrated to GitHub (though they won't officially admit it), DevOps is a great service with a lovely UI.

The pipeline docs are somewhat lacking though IMHO but once you get them working, they work great.

Re:macOS in QEMU in Docker by GordonS on Thursday June 04, 2020 @02:50PM (#23420311)
I've been worried about Azure DevOps getting merged into GitHub since Microsoft bought Github, but thankfully I haven't seen any drop in the maintenance of Azure DevOps, not yet anyway.

As much as I like Github for OSS projects, I really love Azure DevOps for everything else. The CI/CD capabilities are amazing, and I haven't had any real issues with lack of documentation (a few small things here and there for sure though).

Long may it live, I hope!

Re:macOS in QEMU in Docker by lalos on Thursday June 04, 2020 @03:22PM (#23420688)
I doubt it, the valuable thing is the GitHub brand but the meat lies on Azure. Most developers still see Microsoft as the old Microsoft of the 90s but they are actively working on that image or brand by acquisitions like Github or NPM. The inverse is most likely where GitHub is just a web endpoint for underlying Azure services.
Re:macOS in QEMU in Docker by sitkack on Thursday June 04, 2020 @04:37PM (#23421465)
> old Microsoft of the 90s

Not to jackknife the thread, but most developers were born in the 90s and do not remember this Microsoft.

The engineering and dev managers DO remember this Microsoft. So while I agree somewhat they are trying to repair their image, with the younger crowd they only know MS as Minecraft, VS Code, Azure, Github. More people probably got exposure to Linux via WSL than all of the previous installs combined.

90s me would have thought hell would have frozen over, and now me knows it has.

Re:macOS in QEMU in Docker by pydry on Thursday June 04, 2020 @04:53PM (#23421615)
The only real change I've seen to Microsoft since the 90s is that it finally "embraced" open source in markets it was losing in when the only other alternative was irrelevance.

They're still playing dirty tricks on open source. They're just not stupid enough to use the ones that would do more harm than good.

Re:macOS in QEMU in Docker by sitkack on Thursday June 04, 2020 @06:45PM (#23422873)
Most companies are only using open source as a weapon [1].

When people say that "MS gets open source now", what it really means is the MS gets how OS can be used to further its goals. Not that they have fundamentally changed.

MS will have graduated to the next level of maturity when it open sources something that is strategic to the ecosystem and the ecosystem as a whole benefits (Windows NT 4?) or something that is obviously making them money.

[1] https://www.gwern.net/Complement

Re:macOS in QEMU in Docker by GordonS on Friday June 05, 2020 @04:36AM (#23426309)
> MS will have graduated to the next level of maturity when it open sources something that is strategic to the ecosystem and the ecosystem as a whole benefits

Dotnet Core is cross-platform and fits that bill.

It introduced a huge segment of Windows-only devs to Linux.

Yes, that furthers Microsoft's goals too, as Linux is very important in the cloud, and therefore Azure. But regardless, the move has also benefited many, many developers, and the Linux ecosystem.

Re:macOS in QEMU in Docker by coredog64 on Thursday June 04, 2020 @05:12PM (#23421865)
Microsoft told my previous employer (a very large enterprise customer) that they can expect ADO to be de emphasized at best and retired in favor of the GH offering at worst.
Re:macOS in QEMU in Docker by GordonS on Thursday June 04, 2020 @05:42PM (#23422228)
They've told my employer the exact opposite, that they expect Github and Azure DevOps to coexist peacefully indefinitely, so I guess neither of us should read too much into that!
Re:macOS in QEMU in Docker by loxias on Friday June 05, 2020 @08:58AM (#23427954)
I built a PoC of this before, and as far as I can tell, entirely legally.

End goal was building iOS apps w/o any mac hardware. Using some open source patches to clang, libimobiledevice, and a whole bunch of other tools, I was able to write an iOS app in "good ole C in emacs" on my linux laptop, cross compile it for the iPhone, and even code sign, upload and run it on the phone.

This was several years ago. If offered as a hosted service, do you really think anyone would pay for it enough to make it worth my while to code up and polish?

EDIT: HAH! I forgot I said all this the last time this topic came up 2 years ago: https://news.ycombinator.com/item?id=17763855

Re:macOS in QEMU in Docker by _salmon on Thursday June 04, 2020 @03:06PM (#23420491)
MacStadium is very popular for this purpose.

https://www.macstadium.com/

Re:macOS in QEMU in Docker by hinkley on Thursday June 04, 2020 @04:31PM (#23421403)
My CI/CD pipelines have always been a minmaxed affair of doing the math on how useful a piece of information is and how expensive it is to get.

As such, it's not unusual for the OS X tests to be farther down the list and not to trigger at all if earlier stages failed. It's easier to scale up multiple subprojects if you run the first couple phases on commodity hardware and then ramp up to the more peculiar stuff only if everything else already looks good. That way, your broken build can't slow down my green build very much.

It's not so much that I like doing this, as that it prevents a number of things I most definitely do not like at all.

Re:macOS in QEMU in Docker by tomduncalf on Thursday June 04, 2020 @05:10PM (#23421844)
Azure DevOps has the most reasonably priced Mac nodes I could find, I believe it’s £30/month/node (same pricing as their Windows and Linux nodes). Having to figure out another YAML config for CI isn’t my favourite task but it’s not too hard and we are generally pretty pleased with its performance (using it to build iOS app builds for every change and upload to AppCenter, which is a great free repository for them which hooks into Azure easily). Feel free to get in touch if you’d like more info.
Re:macOS in QEMU in Docker by GordonS on Friday June 05, 2020 @04:39AM (#23426329)
Azure DevOps also has a generous free tier with lots of CI minutes, and I'm fairly sure you can use the MacOS pipelines in that tier.

I've used Azure DevOps on several projects, and it's CI/CD capabilities really are fantastic.

I've also used AppCenter (and the previous incarnation, HockeyApp), and it makes for a great app distribution experience. It also has an integration with InTune, which is very useful in the enterprise, although we did find configurating it to be a total PITA and it required a domain admin to set it up.

Re:macOS in QEMU in Docker by ben509 on Thursday June 04, 2020 @02:46PM (#23420260)
Github Actions has macOS builders. Not sure if they have XCode installed, though.
Re:macOS in QEMU in Docker by tomduncalf on Thursday June 04, 2020 @05:11PM (#23421859)
Wrote a separate comment about this, but Azure DevOps seemed to be quite a bit cheaper for Mac nodes than GH Actions. Strange as they are presumably using Azure under the hood!
Re:macOS in QEMU in Docker by jhasse on Thursday June 04, 2020 @03:15PM (#23420599)
They have.
Re:macOS in QEMU in Docker by lostlogin on Thursday June 04, 2020 @02:41PM (#23420205)
VMs? And to stay within the EULA you’d do this on Mac hardware of course.
Re:macOS in QEMU in Docker by kccqzy on Thursday June 04, 2020 @02:33PM (#23420101)
You can rent Mac servers instead of buying them.
Re:macOS in QEMU in Docker by app4soft on Thursday June 04, 2020 @03:29PM (#23420745)
> I just want a good CI/CD system for macOS to build iOS apps

Why not use Travis CI by adding `.travis.yml` into your GitHub repo?

Re:macOS in QEMU in Docker by lwb on Thursday June 04, 2020 @04:16PM (#23421229)
If you make games, Unity Cloud Build can turn a Unity project into a downloadable IPA that you can easily load into TestFlight/App Store (and presumably a device or simulator, but I've never tried).