79654889

Date: 2025-06-05 16:50:30
Score: 2.5
Natty:
Report link

replying to a 6 years old question.

The direct way to store into a variable is :

LOG_LINE=$(docker logs --tail 1 --timestamps "$container_name" 2>&1 | tail -n 1)

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: DCVolo