Jacob Kaplan-Moss

Tag: Gcp

TIL: Stop storing credentials in plaintext part #624: gspread edition

Here’s how to safely store and use credentials for the Python gspread library, a Python API for Google Sheets.

Background: How To Keep A Secret, by Glyph The most relevant parts start around 15:00, but watch the whole thing, it’s great and worth your time.

Pre-requisites

Install keyring: pip install keyring or equivalent.

Storing credentials

Create service account credentials as explained in the gspread docs. This ends with you having a JSON credentials file on your disk somewhere (unacceptable).

August 18th, 2023 β€’ credentials gcp gspread keyring security

πŸ“£ Now on Google Cloud Run

A quick announcement: as a bit of an experiment, I’ve moved this site to Google Cloud Run. Please let me know if anything seems broken.

I may in the future write a bit about Cloud Run: there’s a lot to like, and also some definite here-be-dragons things. In the meantime, though, my capsule review:

Here's my capsule review of Cloud Run / Cloud SQL / Cloud Build, from a Heroku stan: πŸ‘πŸ» native Docker, no weirdness πŸ‘πŸ» don't pay for idle time! πŸ‘πŸ» cool access control, traffic options πŸ‘ŽπŸ» the build/release/deploy pipeline is complex af πŸ‘ŽπŸ» docs are terrible πŸ‘ŽπŸ» cli ux is worse
β€” @jacobian

And here’s the code changes I made, including some yak shaving, for your perusal.

January 5th, 2020 β€’ announcements cloudrun gcp google