Skip to content

deploying a function with memory: '4GB' leads to getting deployed with the default 256MB #834

@leon

Description

@leon

Related issues

We have some cpu and memory intensive image resizes in a cloud function.
We have been using the max 2GB in production and everything has worked well.
I now wanted to make it even faster and so I changed to the new 4GB option.

But when I deploy it defaults back to 256MB

[REQUIRED] Version info

node:
node for development: v14.15.2
node set for functions: 12

firebase-functions:
3.13.0

firebase-tools:
9.1.0

firebase-admin:
9.4.2

[REQUIRED] Test case

export const storage = functions
  .region('europe-west1')
  .runWith({
    memory: '4GB',
    timeoutSeconds: 540,
  })
  .storage.bucket('my-special-bucket')
  .object()
  .onFinalize(projectStorageRouter)

[REQUIRED] Steps to reproduce

firebase deploy --only functions:storage

[REQUIRED] Expected behavior

function should deploy with 4GB memory

[REQUIRED] Actual behavior

function deploys with 256MB memory

Were you able to successfully deploy your functions?

yes it deploys as usual but with wrong memory setting

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions