Gcp/Firebase/CloudFunctions/cron
提供: 初心者エンジニアの簡易メモ
cron(スケジュール)の使い方
asia-northeast1リージョンで、タイムゾーンを日本
exports.scheduledFunctionCrontab = functions .region('asia-northeast1') .pubsub.schedule('28 17 * * *') .timeZone('Asia/Tokyo') // Users can choose timezone - default is America/Los_Angeles .onRun((context) => { console.log('This will be run every day at 17:28 Eastern!'); return null; });
deploy
firebase deploy --only functions:scheduledFunctionCrontab