I’m toying with the idea of moving my app off of GCP and onto Digital Ocean (trying to reduce costs). My user tokens are saved in redis along with other state data. So naturally I need to move the backup file created by redis from GCP to digital ocean. Luckily kubernetes comes with this handy tool built into kubectl that will copy any data from the mounted directory of a pod. Pretty sweet.

kubectl cp  redis-0:dump.rdb ~/myredis/.