# /usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found

**URL:** https://discuss.elastic.co/t/usr-local-bin-docker-entrypoint-line-8-exec-filebeat-not-found/149935
**Category:** Beats
**Tags:** filebeat
**Created:** [September 26, 2018, 6:30am UTC](https://discuss.elastic.co/t/usr-local-bin-docker-entrypoint-line-8-exec-filebeat-not-found/149935 "2018-09-26T06:30:16Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![elk11](https://avatars.discourse-cdn.com/v4/letter/e/45deac/32.png) [@elk11](https://discuss.elastic.co/u/elk11)
#### Post date: [September 26, 2018, 6:30am UTC](https://discuss.elastic.co/t/usr-local-bin-docker-entrypoint-line-8-exec-filebeat-not-found/149935/1 "2018-09-26T06:30:17Z")

</div>

I deployed filebeat container through ansible. The container went in restarting loop.

Below is the output of 'docker logs filebeat'

```
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found
/usr/local/bin/docker-entrypoint: line 8: exec: filebeat: not found

```

But when i pull the image manually and run a container from it, it's working all fine.

Where am I going wrong here?

Below is my ansible role to deploy filebeat container:

```
- name: Create filebeat config volume
  file: path={{ filebeat_config_host_path }}
        state=directory
        owner={{ filebeat_uid }}
        group={{ filebeat_group_uid }}
        mode=0755

- name: Copy filebeat conf to host
  template: src=filebeat.yml
            dest={{ filebeat_config_host_path }}

- name: Create filebeat container
  docker_container:
    name: "filebeat"
    image: "{{filebeat_image}}"
    volumes:
      - "/var/lib/docker/containers:/usr/share/filebeat/dockerlogs"
      - "/var/run/docker.sock:/var/run/docker.sock"
      - "{{ filebeat_config_host_path }}:{{ filebeat_config_container_path }}"
    restart_policy: always
    state: started
    recreate: yes
```

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [September 26, 2018, 9:14pm UTC](https://discuss.elastic.co/t/usr-local-bin-docker-entrypoint-line-8-exec-filebeat-not-found/149935/2 "2018-09-26T21:14:57Z")

</div>

Can you share the content of your docker-entrypoint file?

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [October 24, 2018, 9:15pm UTC](https://discuss.elastic.co/t/usr-local-bin-docker-entrypoint-line-8-exec-filebeat-not-found/149935/3 "2018-10-24T21:15:08Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
