Open GoogleCodeExporter opened 8 years ago
Can you share the app.yaml used?
If you don't want to share it publicly, feel free to send it me personally at
dlorenc@google.com
Original comment by dlor...@google.com
on 22 Sep 2015 at 4:29
Sure, here's the full app.yaml -- not much to it. As noted at the bottom, the
build process appends more (secret) env variables to the file prior to invoking
gcloud preview app deploy.
runtime: custom
vm: true
api_version: 1
module: default
handlers:
- url: /_ah/health
login: admin
resources:
cpu: 1
memory_gb: 3
disk_size_gb: 10
automatic_scaling:
min_num_instances: 2
max_num_instances: 5
cool_down_period_sec: 60
cpu_utilization:
target_utilization: 0.75
health_check:
enable_health_check: True
check_interval_sec: 10
timeout_sec: 9
unhealthy_threshold: 2
healthy_threshold: 1
restart_threshold: 3
env_variables:
NODE_ENV: production
MEMORY_AVAILABLE: 3840
REVIEWABLE_FIREBASE: reviewable
REVIEWABLE_LOGGLY_SUBDOMAIN: reviewable
# Shippable will automatically append more env variables here, so keep this at the end!
Original comment by pi...@ideanest.com
on 22 Sep 2015 at 7:27
Ah, thanks. It looks like a bug in our documentation and our parser. Can you
try changing your handlers: section to:
handlers:
- url: /_ah/health
login: admin
script: UNUSED
The script value doesn't actually matter, but our parser requires that it
exists.
If this fixes your issue I'll get the docs updated ASAP and log a bug to fix
the parser.
Original comment by dlor...@google.com
on 22 Sep 2015 at 9:17
That worked, thanks. I now get a permission request page when trying to access
/_ah/health. I guess I'd really like it to be treated like /_ah/start (which
returns a 404 externally) but I guess there's no way to do that?
Original comment by pi...@ideanest.com
on 22 Sep 2015 at 9:32
Could you try setting the "auth_fail_action"? It looks like "unauthorized"
might get you the behavior you're looking for.
https://cloud.google.com/appengine/docs/python/config/appconfig#Python_app_yaml_
Secure_URLs
Original comment by dlor...@google.com
on 22 Sep 2015 at 9:41
Awesome, that worked! Apologies for relying on my 3-year-old knowledge of
app.yaml specs, I guess a few new things got added in the meantime. ;)
Original comment by pi...@ideanest.com
on 22 Sep 2015 at 10:30
With one BIG caveat: I realized too late I also had to add another section to
open up the rest of the URL space. Apparently it's all open by default, but
adding any handler declaration closes off the rest. So, for future readers:
handlers:
- url: /_ah/health
login: admin
auth_fail_action: unauthorized
script: UNUSED
- url: /.*
script: UNUSED
Original comment by pi...@ideanest.com
on 23 Sep 2015 at 8:30
Original comment by gsfow...@google.com
on 23 Sep 2015 at 1:36
Original comment by z...@google.com
on 23 Sep 2015 at 1:40
Original issue reported on code.google.com by
pi...@ideanest.com
on 19 Sep 2015 at 8:58