I'm pushing an update to an existing

I'm pushing an update to an existing container, I get a successful reply from wrangler containers push (though, it was suspiciously fast):
⛅️ wrangler 4.21.2
───────────────────
▲ [WARNING] 🚧 `wrangler containers push` is an open-beta command. Please report any issues to https://github.com/cloudflare/workers-sdk/issues/new/choose


Login Succeeded
The push refers to repository [registry.cloudflare.com/<snip>/myimage]
<snip>: Layer already exists
cf: digest: sha256:<snip>size: 530
Pushed image: registry.cloudflare.com/<snip>/myimage:cf
⛅️ wrangler 4.21.2
───────────────────
▲ [WARNING] 🚧 `wrangler containers push` is an open-beta command. Please report any issues to https://github.com/cloudflare/workers-sdk/issues/new/choose


Login Succeeded
The push refers to repository [registry.cloudflare.com/<snip>/myimage]
<snip>: Layer already exists
cf: digest: sha256:<snip>size: 530
Pushed image: registry.cloudflare.com/<snip>/myimage:cf
but on the containers dashboard, my "Last Modified" says it's been unchanged since approximately my first deploy. (It also never went back to a "pending" state like it did when I first deployed) Is this a bug? Am I doing something wrong? Can they not be updated? (I'm not even seeing a modified_at field in wrangler containers list)
No description
4 Replies
Mike Nomitch
Mike Nomitch2mo ago
Oh so wrangler containers push is used to push the image up to be used later in a Worker. wrangler deploy used to actually update the code So you would either: - Just point to the Dockerfile in your wrangler config and wrangler deploy under image - wrangler push then get the URL and new tag, and then use that URL in image then wrangler deploy So wrangler push would normally be used to add a pre-existing image to your account and/or save an image from some CI build and then when its time to go use it you wrangler deploy I personally like just pointing to a local Dockerfile in my wrangler.jsonc and just building/pushing on wrangler deploy
Phatso
PhatsoOP2mo ago
That'd be nice - I need to run it through the slim toolkit to get it within the size requirements, though. I have a github action that handles the building and pushing (it needs to read the latest git tags, do some logic to determine which tags to apply to the container, etc.).
So wrangler push would normally be used to add a pre-existing image to your account and/or save an image from some CI build
Yeah that sounds like my situation 👍 So my goal is to, on github actions: - tag the image I just built to match what I have on cloudflare registry (and pushed to ghcr) - wrangler containers push the new version of my image to the cloudflare registry - have my workers automatically use the latest image I pushed and then in my wrangler config:
{
"max_instances": 2,
"name": "my-name",
"class_name": "MyClassName",
"image": "registry.cloudflare.com/<snip>/<snip>:cf",
"instance_type": "standard"
}
{
"max_instances": 2,
"name": "my-name",
"class_name": "MyClassName",
"image": "registry.cloudflare.com/<snip>/<snip>:cf",
"instance_type": "standard"
}
For what it's worth, this seems to work. I think the bug here is the "modified at" column isn't updating when I push overtop an existing image I dunno, now I just pushed an image, waited about 30 minutes, and the next time I booted a container it definitely wasn't my new version
Sam Evans
Sam Evans2mo ago
I am dealing with a similar issue where I push an image to the cloudflare registrey, and update the image url in my wrangler.jsonc file, but wrangler deploy specifically ignores the updated tag, and does not use the new image
Mike Nomitch
Mike Nomitch2mo ago
Hrm okay - thanks for reporting - if its 30 min I dont think it's just a rollout taking a little

Did you find this page helpful?