10 ms·
GitHub Actions as a time-sharing supercomputer
- api 3y agoCloud in general is just "mainframe 2.0."
- colonelpopcorn 3y agoDefinitely validates the mainframe architecture though doesn't it?
- jauntywundrkind 3y agoIronically the fastest path to getting everyone connected was to have them talk to cloud data-centers/neo-mainframes. So it both justifies the mainframe, but if you look at why we all went mainframe in the end, it was to, ironically, connect many computers together. There's also the overwhelming issue of power and control. Moving computing back to the mainframe allow totalistic control over computing by the service provider. This is a good way to make money. But is it good for the world? And what would the world look like if we had reliable fast trustable interconnected system, instead of cloud mainframes/data keeps? I'm forgetting which books but some of the books about early computing talked about protests against computerization, against the mass data ingestion (probably among others What The Doormouse Said?). For a while the personal computer was a friendlier less scary mass-roll-out of computing, but this cloud era has not seen many viable alternatives to staying connected while keeping computing personal. RemoteStorage was early in, and Tim Berners Lee trying a seemingly very reasonable Solid idea seem like very reasonable takes, or going full p2p with data/hyper and that world: none of these have the inertia where others can follow suit. The problem is much harder, but I think it's more path dependence and perverse incentives, that breaking out will be found to be quite workable and good and validated, but there's gross inaction on finding the moral, open ecosystem, protocols & standards based alternatives for connecting ourselves together as we might.
- mplewis 3y agoFast, trustable, and interconnected is a function of the infrastructure, so everyone who wants to host still needs a data center.
- jauntywundrkind 3y agoHosting from home seems absurdly viable for many. I have a systemd-timer that keeps a upnp-igd nat hole punched so I can ssh in, and that has absurdly good uptime. My fiber to the home would survive to quite a lot of use. Past that, vps can be had so cheap. If we have good software, the computing footprint ought to be tiny. One real challenge is scale out. Ideally, for p2p to really work, some multi-tenant systems seem required, so we can effectively co-host. I loved the sandstorm model, but didn't actually use it, and I think there's further refinement possible. Ideally imo, I could host like 10 apps, but if you want to use one, you spin up your own tenant instance. The lambda engine/serverless/FaaS thing wouldn't actually spin up new runtimes, it'd use the same FaaS instances, but be fed your tenant context when it ran and only be able to access your tenant stuff. That way as a host, I kind of know & can manage what runs, but you can have your own freedom of configuring your own instance to a large degree. Then we need front ends that let you traffic steer and any cast in fancy ways, so you can host your own but it falls back to me, or you have 10 peers helping you host & you can weight between them. Operationalizing what we have already & finding efficient wins to scale is kind of cart before the horse, since fediverse &Al are so new, but I think the deployment/management model to let us scale our footprint beyond ourselves is a crucial leap. And I think we are remarkably closer than we might think, that the jump into a bigger more holistic pattern is possible if we leverage the excellent serverless runtimes & operational tools that have recently merged integratively.
- o11c 3y agoIt's not a mainframe unless IBM ships 6 entirely different OSes for it.
- nordsieck 3y agoIndeed. http://www.winestockwebdesign.com/Essays/Eternal_Mainframe.html http://www.winestockwebdesign.com/Essays/Eternal_Mainframe.h...
- kubanczyk 3y agoThank you, much appreciated. While I'm still processing the arguments, the style itself is breathtaking. They don't make sentences like this anymore: > Home computers are not unusual, anymore; the novelty is gone.
- nordsieck 3y agoIf you're a fan of elegant prose, I can't recommend Epicurian Dealmaker[1] enough. Sadly, the blog hasn't been written to in 8-ish years now. But I suspect that most of the information is still probably reasonably accurate. --- 1. https://epicureandealmaker.blogspot.com/2013/02/table-of-contents.html https://epicureandealmaker.blogspot.com/2013/02/table-of-con...
- ndiddy 3y agoThe approach the author describes is batch processing, not time sharing. The whole point of time sharing was to allow users to work with the computer interactively rather than having to submit a job and wait for results.
- jamesblonde 3y agoYes. In the courses I give on MLOps, we use Github Actions to run on a schedule: 1. feature pipelines 2. batch inference pipelines
- ipsum2 3y agoI needed to setup GitHub actions for several open source repos for automated CI/CD, using it for ML pipelines seems awful.
- jamesblonde 3y agoI would love to hear your suggestion of an alternative free platform that can be used to run python programs on a schedule with.
- Waterluvian 3y agoThis reminds me of my dad talking about how amazing it was when time-sharing became a thing at UWaterloo. He'd talk about how batch-processing was such a pain when you'd discover some tiny error and have to get back in line, and how with time-sharing you could show up at 3am and have an entire PDP to yourself.
- dekhn 3y agoMy PhD advisor stayed up late at night (in the '60s) to get exclusive access to an IBM mainframe that was normally used at UC for payroll. When I joined the lab the convention was to go find a machine that was only lightly loaded (manually; there was no batch queue, just telnet to a cluster of machines) and start your multi-month simulation and hope nobody else popped onto the machine to steal half your processor.
- kevmo314 3y ago"super" seems a bit generous. Actions runners have always felt slow to me. Fast enough to get the job done for CI/CD but for a batch job running it locally would be faster. This idea does leech free compute in an API-agnostic way though, if this could be tied together with a GCP free tier, AWS free instance, etc I wonder if you could cobble together enough free resources to run everything you wanted.
- ranting-moth 3y agoGitHub Actions computing time is crazy expensive. Especially the Mac prices.
- deleted 3y ago[deleted]
- judge2020 3y agoRunning macOS legally requires real mac servers and a bespoke storage solution: https://www.datacenterdynamics.com/en/analysis/not-just-stacks-macs-racks/ https://www.datacenterdynamics.com/en/analysis/not-just-stac... A self-hosted macOS runner will be more economical in the long-run, if you have a spot you can hook it up at; or, if you're fine doing things less than legally, you can use https://github.com/sickcodes/Docker-OSX https://github.com/sickcodes/Docker-OSX.
- actionfromafar 3y agoI'm sure legality depends on jurisdiction, too. If you acquired the software legally and you need to keep it running in a VM, I'm sure it's legal at least in some places. But yeah, just drive-by-downloading MacOS to your Windows box it is probably not quite on the up and up.
- chpatrick 3y agoOr get one from Hetzner (there's one in the server finder right now for 64/month).
- 255kb 3y agoTo add to this, they recently published a video showing how they provision and manage their macOS runners: https://www.youtube.com/watch?v=I2J2MzKjcqY https://www.youtube.com/watch?v=I2J2MzKjcqY
- xjia 3y agoWe are working on an alternative that's 100% compatible with GHA but much cheaper and faster. Check out https://dime.run/ https://dime.run/
- tomComb 3y agoWhy do actions use VM’s instead of containers? And yet codespaces use containers.
- autoexecbat 3y agosometimes you need to be able to run containers within your action, which can get complicated if you're already in a container
- falcor84 3y agoIs there an inherent complication here?
- fermuch 3y agoThere are some! This is called "Docker in Docker", and you need to expose your docker socket to the container, which has some security implications. It can be secured, as gitpod does, but as I understand it is a PITA.
- bo0tzz 3y ago> you need to expose your docker socket to the container I always thought this was a hard limitation, but I deployed some self-hosted GHA runners in Kubernetes this week and to my surprise that setup came with an option to run the full docker daemon inside of a container - so apparently it is possible.
- alexellisuk 3y agoIf you're running a full docker daemon, then you'll be running as a privileged container which is worse or about the same in terms of terms of poor security. Anyone's workload can compromise the host, and likely the cluster. Rootless containers are a lot of work and do not support many scenarios that you're going to need. MicroVMs are the same experience as GitHub, full system and Kernel, do what you will. Even launch a nested VM.
- aberoham 3y agoAlex's product vision is fantastic. I hope https://github.com/self-actuated https://github.com/self-actuated gets noticed by more folks out there who are hitting the limits of GitHub's hosted runners.
- k8svet 3y agoSeems like a solid tech approach too. I'm surprised there isn't more of this around GHA. It really feels like Microsoft calibrated exactly good enough, yet everyone seems to have their own piles of workarounds in published actions, even bigger piles in their infra, and then some more in the workflow yamls themselves, to get everything actually workings, especially when you need to support GHA runners, self-hosted runners, ARC runners, `act` runners, etc. If they can foster an OSS community around easy self-hosted, and then also offer a hosted runners product that is priced well. I'd pay 'em.
- onedr0p 3y ago[flagged]
- imiric 3y agoNeat, this is a great simulation of eventual computing. When GH Actions goes down, it would be like your time-sharing quota has run out. (:
- gchamonlive 3y agoI know this is tangential to the linked article, but why the "Open" in OpenFaaS if the community edition is so limited? The first payment tier is 1000 dollars. Is that open in the sense you can send pull request and inspect code?
- dmattia 3y ago> "is GitHub Actions production ready? The answer is yes, so by proxy, you could run this tool in production" I sent this to some of my coworkers for a good laugh.
- ch4s3 3y agoour ops group imposed Github Actions on us and build times have tippled on top of being less reliable.
- thewakalix 3y agoTIL production-readiness is contagious.
- mbreese 3y agoMaybe it should thought of as production-adjacent...
- posix86 3y ago> There's something persuasive about running jobs and I don't think it's because developers "don't want to maintain infrastructure". I remember taking a small university course on Ethereum, and getting an introduction smart contracts, trustless environments, and so on. We then heard about a couple of example projects, and were finally asked for our own ideas. Now, after learning a bit more, I'm pretty sure none if the ideas presented either by the lecturers, me, or the other students really benefitted from the trustless environment, which is mostly what you'd use Ethereum for, and arguably what you pay (a lot) for during contract execution. Yet there were so many ideas about what could be done using smart contracts which were really cool projects on their own. I think a big world computer with nodes that can perform calculations, react to user input, be called from other nodes, and exchange tokens and information, is somehow an incredibly natural abstraction that humans can work very well with. So, agreed.
- ufo 3y agoOne thing that I still don't understand about github actions is how much computing power gets wasted downloading and reinstalling the same dependencies over and over. A build that takes a couple of seconds in my local machine can easily take several minutes in github actions.
- 0cf8612b2e1e 3y agoGitHub charges per minute. Some incentive to keep actions on the most under specced machines available.
- Raed667 3y agoDo other CI services do it differently? I worked with Jenkins and Circleci and it was exactly the same. For github actions caching was fairly easy to add.
- ufo 3y agoLast time I tried to add caching to my actions, I spent several hours and still couldn't get it to work properly in the end. I really wonder how many computing hours have been wasted because the default and most likely to work is to not cache anything.
- aeyes 3y agoOn CircleCI it's also easy to add using save_cache and restore_cache, the docs have examples for different popular frameworks. There are a couple of advanced features and I have been able to cache most build artifacts. They also cache the Docker images without you having to do anything but it really only works if you use their base images. With custom images the cache rate doesn't look great in my experience but I have no stats to back that up.
- codetrotter 3y agoYeah. We have a similar thing going on with self-hosted GitLab at my work. (And there, there isn’t even any incentive why it should be slow.) When I make an edit and rebuild on my computer, it takes a few seconds to rebuild because most things are cached. In CI it takes 20 minutes on the MR branches of our repo. 30 minutes on master. Because a whole bunch of crap is downloaded from scratch and rebuilt from scratch. Our infrastructure guys did set up something that is able to cache stuff that some of the repos use. But with the limited access I have I have not been able to figure out how to make use of it for the repo I work on. And they don’t have time to look into it for me either. That’s my life lol
- dweinus 3y ago...and this is why we can't have nice things
- keepamovin 3y agoThis is really cool, Alex: the ability to run arbitrary jobs on GitHub actions that you've wrapped into a convenient API that (I guess) automatically runs on the 3000 free-minutes that every GH account gets on default Ubuntu-runner actions every month. Super cool, I love this idea! Less general than you, but I also had a notion to do kewl shit on GH actions, and I figured out how to turn it into a "personal ephemeral VPN-like" using BrowserBox. Basically, you: 1. fork/generate the BrowserBox project into your own account 2. enable Actions and issues on the fork, and 3. open a new issue from the "Make VPN" issue template which triggers the action to create your remote browser and gives you a login link. And voila! In a few minutes you get an up and running remote browser/private VPN that runs for 15 minutes or so (conservation, but you can tweak the value in the actions yaml!), Even cooler, the action job will post comments guiding you through any setup steps you need, and then post the login link for your BrowserBox instance into the comments section of the issue you opened! Here's the action yaml that I use to do this^0 One hassle: I have still not avoided is the necessity of using ngrok for this. Sure, you can get around it using a tor hidden service which we also support, but that requires the user connecting via a tor browser. Ngrok is required to create the tunnel from the BrowserBox running inside the GH Actions Runner, to the outside world.* Seems like a lot of steps, right? So I added a "conversational" set of instructions auto posted by the runner as issue comments to guide you through it. Check it out la! :) https://github.com/BrowserBox/BrowserBox?tab=readme-ov-file#special-event--create-a-private-ephemeral-web-proxy-hosted-on-your-github-actions-minutes-by-opening-an-issue-on-this-repo https://github.com/BrowserBox/BrowserBox?tab=readme-ov-file#... * Technically, this is probably possible by using mkcert on the IP address of the runner, and posting the rootCA.pem as an attachment to an issue comment. You then need to add it to your trust store and you're good to go, but ngrok is the easier way: sign up to ngrok, get your API key, add it to the Repository Secrets in settings and hit the "Make VPN" issue. 0: https://github.com/BrowserBox/BrowserBox/blob/boss/.github/workflows/userjob.yaml https://github.com/BrowserBox/BrowserBox/blob/boss/.github/w...
- sausagefeet 3y agoThe company I co-founded (Terrateam) develops a Terraform/OpenTofu GitOps CI/CD that focuses on GitHub. We use GitHub to run the operations, for a number of reasons, but we treat it just like ephemeral compute. We initiate the run, basically a near blank image, with our runner on it, and it "morphs" the image into what we need to do for that run. It works really well, except that GitHub Actions can be slow and I think they haven't quite figured out how to do reliable operations for it, yet. The major thing about the API that I don't like is when you initiate a GHA run via the API, it does not give you an ID that you can use to track it. So if you initiate and it either never runs or fails for some reason prior to any code you put on the image, there is no good way to track that.