With Codefresh, you can automatically push your build images to your Docker registry.
You select this option when you configure your service.
What's a Docker registry? Learn more at the Docker Documentation Center
- Click the Services view icon to display the service you created.
- Click the Gear icon on the service profile.
Services view (click image to enlarge)
- Navigate to the Build and Unit Test section.
- In the Image Name text box, type a name for your image.
Notice that the name you define is important and you should provide a name that will be accepted by your Docker registry.
Define the image name (click image to enlarge)
Scroll to the Push to Docker registry section.
If you haven't configured your Docker Hub registry credentials you are prompted to do so.
Navigate to Integration page (click image to enlarge)
On the integration page, enter your Docker Hub credentials and click SAVE.
Now, navigate back to your service's configuration page.
Setting credentials (click image to enlarge)
Want to push your image to a different registry? Check out our Docker Registry integration documentation .
- Scroll to the Push to Docker Registry section and click on the Docker icon.
- On the bottom of the service configuration page, click the SAVE button.
Automatic push enabled (click image to enlarge)
To trigger a new build, click the BUILD button.
When your image builds, it is automatically pushed to your defined registry.
Trigger a new build (click image to enlarge)