Original article, welcome to reprint. Reprint please specify: reprint from IT people story, thank you! Docker Cloud automatically builds Docker image
Step by step, github will automatically build a Docker image over time
Login docker cloud
You can log in with a Docker account.
Associate with Github
This is according to your own account to me is: cloud.docker.com/swarm/zhuge…
- Go to the Settings for Person
- Github set authorization
Github and Docker Cloud have been associated
Link to complete
Create a build relationship
You can skip this one
Creating a successful
Move to the new DockerCloudTest
The command is created successfully. Procedure
Github associate builds with each other
Select the path corresponding to the Dockfile, remember path
Change to path
Click Save to go to the page, click trigger
The first build was successful, but there were some failures later, because after all, it was free to use a public resource pool, which required queuing. If you were nervous, you would inevitably fail, and you would also need to wait for a period of time to create a build.
Automatically build
Open button to modify Dockerfile automatically created after saving.
Automatic execution.
Github added the Release branch to tag
How do you tag
- New release
- Hit Ceate a New Release
- Hit Create success
The following diagram should change the rule from 1.0 to 1.0.0. There should be a rule for defining a tag in a build.
- Click on finish
- Click Modify Docker Cloud to modify
- Add build rule
Tag rules should be consistent
Start waiting for discovery.
It’s also on hub.docker.com
PS: Automatic build image, does not feel very cool, but the Dockfile here needs a solid foundation. This section is also the basis for future study.