Hacker Newsnew | past | comments | ask | show | jobs | submit | bo0tzz's commentslogin

> correctly classified as having user generated active content

No it's not

> PRs can be autodeployed to this domain without passing review or approval.

No they can't

There is no untrusted/user content on these domains.


As I've mentioned in several other comments in this thread by now: The whole preview functionality only works for internal PRs, untrusted ones would never even make it to deployment.


> unless one of the developers in the team published something malicious through that system

If that happened we'd have much bigger problems than Google's flagging.


> Google flagged this domain for legitimate reasons.

No they didn't.


There is no user generated content involved here.


The Immich domains that are hit by this issue are -not- user generated content.


They clearly are? It seems like GitHub users submitting a PR could/can add a `preview` label, and that would lead to the application + their changes to be deployed to a public URL under "*.immich.cloud". So they're hosted content generated by users (built application based on user patches) on domains under their control.


I'm the guy that built the system, lol. Labels can only be added by maintainers, and the whole system only works for PRs from internal branches.


Ah, then that's a different situation then, sorry for misunderstanding the context and thanks for clearing that up! I was under the impression that Immich accepted outside contributions, and those would also have those preview sites created for their pending contributions.


The workflow is fundamentally unable to deploy a PR from a fork, it only works for internal branches, as it relies on the container image being pushed somewhere which needs secrets available in the CI workflow.


Sounds like you're hitting an address that isn't backed by any service, not sure what the issue is.


If anyone's got questions about this setup I'd be happy to chat about it!


I’m curious about basically all of it. It seems like such a powerful tool.

I seem to have irritated the parallel commenters tremendously by asking, but it seemed implausible I’d understand the design considerations by just skimming the CI config.

Top of mind would be:

1. How do y'all think about mitigating the risk of somebody launching malicious or spammy PR sites? Is there a limiting factor on whose PRs trigger a launch?

2. Have you seen resource constraint issues or impact to how PRs are used by devs? It seems like Immich is popular enough that it could easily have a ton of inflight PR dev (and thus a ton of parallel PR instances eating resources)

3. Did you borrow this pattern from elsewhere / do you think the current implementation of CI hooks into k8s would be generalizable? I’ve seen this kind of PR preview functionality in other repos that build assets (like CLI tools) or static content (like docs sites), but I think this is the first time I’ve seen it for something that’s a networked service.


1. It only works at all for internal PRs, not for forks. That is a limitation we'd like to lift if we could figure out a way to do it safely though.

2. It's running on a pretty big machine, so I haven't seen it approach any limits yet. We also only create an instance when requested (with a PR label).

3. I've of course been inspired by other examples, but I think the current pattern is mostly my own, if largely just one of the core uses of the flux-operator ResourceSet APIs [1]. It's absolutely generalizable - the main 'loop' [2] just templates whatever Kubernetes resources based on the existence of a PR, you could put absolutely anything in there.

[1]: https://fluxcd.control-plane.io/operator/resourcesets/github...

[2]: https://github.com/immich-app/devtools/blob/main/kubernetes/...


> what Immich is doing here is extremely dangerous

You fully misunderstand what content is hosted on these sites. It's only builds from internal branches by the core team, there is no path for "external user" content to land on this domain.


It's builds from PRs that can be submitted by anyone with a GitHub account


Dude, I built it, surely I'd know how it works...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: