{"id":267,"date":"2024-06-12T12:46:18","date_gmt":"2024-06-12T09:46:18","guid":{"rendered":"https:\/\/dinodevs.com\/blog\/?p=267"},"modified":"2025-09-30T02:02:01","modified_gmt":"2025-09-29T23:02:01","slug":"fantastic-docker-hiccups-and-how-to-fix-them","status":"publish","type":"post","link":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/","title":{"rendered":"Fantastic Docker Hiccups and How to Fix Them"},"content":{"rendered":"\n<p>If you have encountered unexpected issues while working with Docker&#8230; you are in the right place!<\/p>\n\n\n\n<p>Whether you&#8217;re a seasoned Docker user or just getting started, you may have encountered some unexpected &#8220;hiccups&#8221; along the way. In this article, we&#8217;ll analyse various Docker hiccups that I have experienced while developing and administrating servers, and try to provide practical solutions to fix them.<\/p>\n\n\n\n<p>Buckle up and get ready to tackle those Docker challenges head-on!<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Hiccups Covered<\/h3>\n\n\n\n<p>Here is a list of small problems that we will try to fix:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Huge Container Logs<\/li>\n<\/ul>\n\n\n\n<p>I plan to update this article from time to time with more small Docker problems that I find interesting.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Huge Container Logs<\/h2>\n\n\n\n<p>As a naive and noob Docker user, I was under the impression that each container&#8217;s logs were automatically trimmed to minimise disk space usage. But&#8230; this is not the case, as Docker by default keeps all the logs&#8230; and I had to find it the hard way one day that some services were throwing error 500 and on further inspection, I found out that a server hosting 2 GitLab containers run out of disk space (each instance generated 39GB of logs).<\/p>\n\n\n\n<p>To address the issue, I found out that I could configure each one of my containers to limit the log file in size and number. For projects deployed as a <code>docker-compose.yml<\/code>, one can configure the logging behavior of each service to apply these limits. Here is an example:<\/p>\n\n\n\n<pre class=\"wp-block-code lang-yaml\"><code>services:\n  example:\n    image: hello-world:latest\n    restart: unless-stopped\n    logging:\n      driver: json-file\n      options:\n        max-size: \"10m\"\n        max-file: \"5\"<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>If you have encountered unexpected issues while working with Docker&#8230; you are in the right place! Whether you&#8217;re a seasoned Docker user or just getting started, you may have encountered some unexpected &#8220;hiccups&#8221; along the way. In this article, we&#8217;ll analyse various Docker hiccups that I have experienced while developing and administrating servers, and try [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":269,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[16,14],"class_list":["post-267","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","tag-docker","tag-server"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.0 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Fantastic Docker Hiccups and How to Fix Them - DinoDevs<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Fantastic Docker Hiccups and How to Fix Them - DinoDevs\" \/>\n<meta property=\"og:description\" content=\"If you have encountered unexpected issues while working with Docker&#8230; you are in the right place! Whether you&#8217;re a seasoned Docker user or just getting started, you may have encountered some unexpected &#8220;hiccups&#8221; along the way. In this article, we&#8217;ll analyse various Docker hiccups that I have experienced while developing and administrating servers, and try [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\" \/>\n<meta property=\"og:site_name\" content=\"DinoDevs\" \/>\n<meta property=\"article:published_time\" content=\"2024-06-12T09:46:18+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-09-29T23:02:01+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"346\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Athanasios Grammatopoulos\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Athanasios Grammatopoulos\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\"},\"author\":{\"name\":\"Athanasios Grammatopoulos\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/fccac7bcc5374cede43de49a450dfaf3\"},\"headline\":\"Fantastic Docker Hiccups and How to Fix Them\",\"datePublished\":\"2024-06-12T09:46:18+00:00\",\"dateModified\":\"2025-09-29T23:02:01+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\"},\"wordCount\":250,\"publisher\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png\",\"keywords\":[\"docker\",\"server\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\",\"url\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\",\"name\":\"Fantastic Docker Hiccups and How to Fix Them - DinoDevs\",\"isPartOf\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png\",\"datePublished\":\"2024-06-12T09:46:18+00:00\",\"dateModified\":\"2025-09-29T23:02:01+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage\",\"url\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png\",\"contentUrl\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png\",\"width\":1024,\"height\":346},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/dinodevs.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Fantastic Docker Hiccups and How to Fix Them\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#website\",\"url\":\"https:\/\/dinodevs.com\/blog\/\",\"name\":\"DinoDevs\",\"description\":\"When in doubt, code it out.\",\"publisher\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/dinodevs.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#organization\",\"name\":\"DinoDevs\",\"url\":\"https:\/\/dinodevs.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2025\/05\/dinodevs.cube_.png\",\"contentUrl\":\"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2025\/05\/dinodevs.cube_.png\",\"width\":600,\"height\":600,\"caption\":\"DinoDevs\"},\"image\":{\"@id\":\"https:\/\/dinodevs.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/fccac7bcc5374cede43de49a450dfaf3\",\"name\":\"Athanasios Grammatopoulos\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/0271fabc59edad96ed659fb1a3c4caf867a7324609e22d0b2cc25ad71d4c0d8c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/0271fabc59edad96ed659fb1a3c4caf867a7324609e22d0b2cc25ad71d4c0d8c?s=96&d=mm&r=g\",\"caption\":\"Athanasios Grammatopoulos\"},\"sameAs\":[\"https:\/\/github.com\/GramThanos\"],\"url\":\"https:\/\/dinodevs.com\/blog\/author\/gramthanos\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Fantastic Docker Hiccups and How to Fix Them - DinoDevs","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/","og_locale":"en_US","og_type":"article","og_title":"Fantastic Docker Hiccups and How to Fix Them - DinoDevs","og_description":"If you have encountered unexpected issues while working with Docker&#8230; you are in the right place! Whether you&#8217;re a seasoned Docker user or just getting started, you may have encountered some unexpected &#8220;hiccups&#8221; along the way. In this article, we&#8217;ll analyse various Docker hiccups that I have experienced while developing and administrating servers, and try [&hellip;]","og_url":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/","og_site_name":"DinoDevs","article_published_time":"2024-06-12T09:46:18+00:00","article_modified_time":"2025-09-29T23:02:01+00:00","og_image":[{"width":1024,"height":346,"url":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png","type":"image\/png"}],"author":"Athanasios Grammatopoulos","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Athanasios Grammatopoulos","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#article","isPartOf":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/"},"author":{"name":"Athanasios Grammatopoulos","@id":"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/fccac7bcc5374cede43de49a450dfaf3"},"headline":"Fantastic Docker Hiccups and How to Fix Them","datePublished":"2024-06-12T09:46:18+00:00","dateModified":"2025-09-29T23:02:01+00:00","mainEntityOfPage":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/"},"wordCount":250,"publisher":{"@id":"https:\/\/dinodevs.com\/blog\/#organization"},"image":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage"},"thumbnailUrl":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png","keywords":["docker","server"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/","url":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/","name":"Fantastic Docker Hiccups and How to Fix Them - DinoDevs","isPartOf":{"@id":"https:\/\/dinodevs.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage"},"image":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage"},"thumbnailUrl":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png","datePublished":"2024-06-12T09:46:18+00:00","dateModified":"2025-09-29T23:02:01+00:00","breadcrumb":{"@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#primaryimage","url":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png","contentUrl":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2024\/06\/docker-on-fire.png","width":1024,"height":346},{"@type":"BreadcrumbList","@id":"https:\/\/dinodevs.com\/blog\/fantastic-docker-hiccups-and-how-to-fix-them\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/dinodevs.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Fantastic Docker Hiccups and How to Fix Them"}]},{"@type":"WebSite","@id":"https:\/\/dinodevs.com\/blog\/#website","url":"https:\/\/dinodevs.com\/blog\/","name":"DinoDevs","description":"When in doubt, code it out.","publisher":{"@id":"https:\/\/dinodevs.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/dinodevs.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/dinodevs.com\/blog\/#organization","name":"DinoDevs","url":"https:\/\/dinodevs.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dinodevs.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2025\/05\/dinodevs.cube_.png","contentUrl":"https:\/\/dinodevs.com\/blog\/wp-content\/uploads\/2025\/05\/dinodevs.cube_.png","width":600,"height":600,"caption":"DinoDevs"},"image":{"@id":"https:\/\/dinodevs.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/fccac7bcc5374cede43de49a450dfaf3","name":"Athanasios Grammatopoulos","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dinodevs.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/0271fabc59edad96ed659fb1a3c4caf867a7324609e22d0b2cc25ad71d4c0d8c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0271fabc59edad96ed659fb1a3c4caf867a7324609e22d0b2cc25ad71d4c0d8c?s=96&d=mm&r=g","caption":"Athanasios Grammatopoulos"},"sameAs":["https:\/\/github.com\/GramThanos"],"url":"https:\/\/dinodevs.com\/blog\/author\/gramthanos\/"}]}},"_links":{"self":[{"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/posts\/267","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/comments?post=267"}],"version-history":[{"count":1,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/posts\/267\/revisions"}],"predecessor-version":[{"id":268,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/posts\/267\/revisions\/268"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/media\/269"}],"wp:attachment":[{"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/media?parent=267"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/categories?post=267"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dinodevs.com\/blog\/wp-json\/wp\/v2\/tags?post=267"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}