*Cloud Run error: Container failed to start. Faile...
# talk-hydra
n
Cloud Run error: Container failed to start. Failed to start and then listen on the port defined by the PORT environment variable. Logs for this revision might contain more information.
d
Are you specifying the port? Cloud Run expects you to listen on
$PORT
by default (typically 8080), but Hydra listens on 4444, 4445 by default
n
I should specify 4444 as the port right?
I have tried both 4444 and 4445. Still doesn’t work for me
d
4444 as the port should work. I’m playing with Hydra on Knative right now (the API Cloud Run is based on), so lemme dig up what I’m going
👍 1
*doing
Copy code
spec:
  template:
    spec:
      containers:
      - image: <http://docker.io/oryd/hydra:v1.10.6|docker.io/oryd/hydra:v1.10.6>
        args: ["serve", "-c", "/etc/config/hydra/hydra.yaml", "all", "--dangerous-force-http"]
        ports:
        - containerPort: 4444
This is the meat of it, the rest is less interesting for Cloud Run, since it uses K8s features for secrets/sidecars
I have it connected to Postgres on Cloud SQL through the IAM proxy
For the Admin stuff, I just run a second (private) service exposing 4445 hitting the same database
n
message has been deleted
This is what I have. It matches your config. Doesn’t work though
d
In mine that hydra config is coming from a volume
You also aren’t forcing http
TLS is terminated before the container, so it should be listening via HTTP