Fix secret access for some email sending functions (#449)
This commit is contained in:
parent
2ac7caaf24
commit
0f0390cb6a
|
@ -5,8 +5,9 @@ import { Contract } from '../../common/contract'
|
|||
import { getPrivateUser, getUserByUsername } from './utils'
|
||||
import { sendMarketCloseEmail } from './emails'
|
||||
|
||||
export const marketCloseEmails = functions.pubsub
|
||||
.schedule('every 1 hours')
|
||||
export const marketCloseEmails = functions
|
||||
.runWith({ secrets: ['MAILGUN_KEY'] })
|
||||
.pubsub.schedule('every 1 hours')
|
||||
.onRun(async () => {
|
||||
await sendMarketCloseEmails()
|
||||
})
|
||||
|
|
|
@ -90,7 +90,7 @@ export const createCheckoutSession = functions
|
|||
export const stripeWebhook = functions
|
||||
.runWith({
|
||||
minInstances: 1,
|
||||
secrets: ['STRIPE_APIKEY', 'STRIPE_WEBHOOKSECRET'],
|
||||
secrets: ['MAILGUN_KEY', 'STRIPE_APIKEY', 'STRIPE_WEBHOOKSECRET'],
|
||||
})
|
||||
.https.onRequest(async (req, res) => {
|
||||
const stripe = initStripe()
|
||||
|
|
Loading…
Reference in New Issue
Block a user