Container Best Practices - Log Forwarding Agent

What is the best practice to install log-forwarding agent (filebeat) to push my application logs ?

  • Should the agent be installed inside the container
  • Mount the container by sharing the application logs directory with the node and have common log-forwarding agent on the node which will push all the container logs

there are a number of filebeat docker images on dockerhub.