admin/ April 24, 2017/ Docker, Linux/ 0 comments

Docker build own Image using Bitrise CI/CD tool

You need three account to automate the Docker image build process.

1. Github ( or Bitbucket (
2. Dockerhub (
3. Bitrise (

1. Github/Bitbucket

SignUp or Login in the Github/Bitbucket. Create an repository.

Configure the Github/Bitbucket on you local system.

Step 1:
Create a directory and configure as below.

Create a file named as “Dockerfile”. Write you docker command statement inside the file which you want to build.
For Example-:

Open your Dockerfile and paste the below line of statement.
To open Dockerfile on Linux

Paste the below lines in the Dockerfile

To Save file, use below command for vi editor.

Step 2:

Commit the Dockerfile and push on the Github/Bitbucket.

2. Dockerhub (

Login the goto dockerhub dashboard.

Step 1:

Go To setting to link the Github Account/Bitbucket Account.

Click on the Setting.

Click on the Link Accounts & Services

Select the access for the repository.

Finally Your Github Account is linked.

Step 2-:

Automate the Docker build.

Click on “Create Automated Build”

Select your Repository Connector

Create your Automated Build.


3. Bitrise (

Bitrise Setup for Automated build the Docker Image.

Step 1:

Login the Bitrise account.
Add you First App

Select Github/Bitbucket to use your repository.

Authenticate your Repository.

Type your branch name if you used except the Master branch.

Validation the Repository

Select the Other/Manual

Use the Stack Selector as “Android $ Docker Ubuntu 16.04”

Register The Webhook.

Click on the Finsh Button on the Right hand on the top button.

Step 2:

Click on the App then open the “Workflow”

Open the Bitrise.yml

Paste the below lines in the bitrise,yml file.

Step 3:

Secret Environment Variables

Fill the docker username in right textbox

Enter the Dockerhub Password.

Enter the Docker image as “Username/RepoName” as in the dockerhub account.

For Example -;

Finally your Bitrise automated Build Docker Image setup has been done.

Click on the Start build after build succeed check the tags in your the Dockerhub.

On the Success of the build Complete.


Check the final image in the Dockerhub tags.


Share this Post

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.