I am uploading images for user profiles to Firebase with a path such as profiles/${userId}/image.jpg
.
After every upload, I trigger a cloud function that gets the signed url with GCS like in this example:
const SIGNED_BUCKET_URL_CONFIG = {
action: 'read',
expires: '03-01-2501'
};
const bucket = gcs.bucket(BUCKET_NAME);
const profileImageRef = bucket.file(`profiles/${userId}/image.jpg`);
const url = profileImageRef.getSignedUrl(SIGNED_BUCKET_URL_CONFIG),
Now my problem is that the returned signed URL is always the same after every upload/overwrite of the image and the mobile app does not know the cache for this image must be refreshed.
Is it maybe possible to generate a signed url with a version param, e.g. '....?v=123' ?