# Error while building docker image

**URL:** <https://forum.ansible.com/t/error-while-building-docker-image/19346>\
**Category:** Ansible Project\
**Created:** [September 23, 2015, 6:33pm UTC](https://forum.ansible.com/t/error-while-building-docker-image/19346 "2015-09-23T18:33:35Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Darvin\_Denmian](https://avatars.discourse-cdn.com/v4/letter/d/c68b51/32.png) [@Darvin\_Denmian](https://forum.ansible.com/u/Darvin_Denmian)\
**Post date:** [September 23, 2015, 6:33pm UTC](https://forum.ansible.com/t/error-while-building-docker-image/19346/1 "2015-09-23T18:33:35Z")

</div>

Hi guys,

I’m facing a weird problem when trying to build a docker image,  
this is the basic workflow:

1. I successfully build a docker image called “accounts-skeleton”

…

- name: “Accounts: building Accounts Skeleton image”  
docker\_image:  
path: /tmp/  
name: accounts-skeleton  
tag: latest  
state: present  
tags:
- containers
- accounts-skeleton

# docker images

REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE  
accounts-skeleton latest c227713a6340 2 hours ago 790.9 MB

1. and then I try to create a second image using the image “accounts-skeleton”,  
as follows:

…

- name: “Accounts: building Accounts Base image”  
docker\_image:  
path: /home/accounts/current/  
name: accounts-base  
tag: latest  
state: present  
when: deploy is defined  
tags:
- containers
- accounts-base

but when I execute the playbook the following error message appears:

TASK: [accounts | Accounts: building Accounts Base image] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
failed: [192.168.1.170] =\> {“changed”: true, “failed”: true, “image\_id”: null}  
msg: Error: Error: image library/accounts-skeleton:latest not found  
Log:Step 0 : FROM accounts-skeleton

Do you guys have some idea of what is going on?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![Darvin\_Denmian](https://avatars.discourse-cdn.com/v4/letter/d/c68b51/32.png) [@Darvin\_Denmian](https://forum.ansible.com/u/Darvin_Denmian)\
**Post date:** [September 24, 2015, 5:25pm UTC](https://forum.ansible.com/t/error-while-building-docker-image/19346/2 "2015-09-24T17:25:41Z")

</div>

Anyone?

---

<div class="post-metadata">

**Author:** ![Anand\_Sampat](https://avatars.discourse-cdn.com/v4/letter/a/cc9497/32.png) [@Anand\_Sampat](https://forum.ansible.com/u/Anand_Sampat)\
**Post date:** [July 29, 2016, 8:24pm UTC](https://forum.ansible.com/t/error-while-building-docker-image/19346/3 "2016-07-29T20:24:18Z")

</div>

Ah I’m having this exact same issue. Did you every find a solution?
