Recently, we started noticing changes not being present in our Docker images pushed to Docker Hub from a BitBucket pipeline. After clearing the pipeline cache, the new changes were picked up and properly pushed. I promptly disabled the cache.
If I can't rely on the cache being updated correctly and our production deployments thus using stale code, the cache is actively harmful and I'm not going to enable it again! What is happening here?
Hi @Moritz Friedrich and welcome to the community.
I'm afraid that, at the moment, the cache in pipelines doesn't get updated when the dependencies are updated.
A cache gets saved on a successful build (if the cache is empty), it gets stored for a week (unless manually cleared), and after it gets cleared a new cache is created on the next successful build. The feature to have it automatically updated while it is saved is not available yet.
We have a feature request for this in our issue tracker:
I would suggest that you add your vote there (by selecting the Vote for this issue link) as the number of votes helps the development team and product managers better understand the demand for new features. You are more than welcome to leave any feedback, and you can also add yourself as a watcher (by selecting the Start watching this issue link) if you'd like to get notified via email on updates.
Implementation of new features is done as per our policy here and any updates will be posted in the feature request.
Please feel free to let me know if you have any questions.
We are excited to announce the open beta program for self-hosted runners. Bitbucket Pipelines Runners is available to everyone. Please try it and let us know your feedback. If you have any issue...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events