feat: initial datalake and stats site (#28666)
This commit is contained in:
parent
633b5d6208
commit
5b02ac4d33
68 changed files with 8967 additions and 42 deletions
|
|
@ -11,6 +11,7 @@ export const Resource = new Proxy(
|
|||
{
|
||||
get(_target, prop: keyof typeof ResourceBase) {
|
||||
const value = ResourceBase[prop]
|
||||
const secrets = ResourceBase as unknown as Record<string, { value: string }>
|
||||
if ("type" in value) {
|
||||
// @ts-ignore
|
||||
if (value.type === "sst.cloudflare.Bucket") {
|
||||
|
|
@ -21,11 +22,11 @@ export const Resource = new Proxy(
|
|||
// @ts-ignore
|
||||
if (value.type === "sst.cloudflare.Kv") {
|
||||
const client = new Cloudflare({
|
||||
apiToken: ResourceBase.CLOUDFLARE_API_TOKEN.value,
|
||||
apiToken: secrets.CLOUDFLARE_API_TOKEN.value,
|
||||
})
|
||||
// @ts-ignore
|
||||
const namespaceId = value.namespaceId
|
||||
const accountId = ResourceBase.CLOUDFLARE_DEFAULT_ACCOUNT_ID.value
|
||||
const accountId = secrets.CLOUDFLARE_DEFAULT_ACCOUNT_ID.value
|
||||
return {
|
||||
get: (k: string | string[]) => {
|
||||
const isMulti = Array.isArray(k)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue