{"id":3300,"date":"2023-11-27T09:04:52","date_gmt":"2023-11-27T15:04:52","guid":{"rendered":"https:\/\/lab.rapternet.us\/?p=3300"},"modified":"2023-11-05T22:14:53","modified_gmt":"2023-11-06T04:14:53","slug":"docker-hub-login-on-unraid","status":"publish","type":"post","link":"https:\/\/lab.rapternet.us\/?p=3300","title":{"rendered":"Docker Hub Login on Unraid"},"content":{"rendered":"\n<p>I&#8217;ve had a few times now where I can&#8217;t grab a new container image to startup due to their rates limits on docker hub. This has been quite annoying, and there is a free plan for double the image pulls. Here is how you can login on unraid and setup the go file so it persists between reboots.<\/p>\n\n\n\n<!--more-->\n\n\n\n<p>To start out you&#8217;ll need a free account on docker hub, we&#8217;ll be using the username and password in our Go script. Since I&#8217;m only using this account for image pulls, I&#8217;m okay with this security posture (plain text password in a script). I also used an auto generated password from Bitwarden, so it&#8217;s unique to this account alone.<\/p>\n\n\n\n<p>You can test with the command below in a terminal to your unraid server.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">root@ShadowOfIntent:\/mnt# docker login -u xxxxxxxxxx<br>Password:<br>WARNING! Your password will be stored unencrypted in \/root\/.docker\/config.json.<br>Configure a credential helper to remove this warning. See<br>https:\/\/docs.docker.com\/engine\/reference\/commandline\/login\/#credentials-store<br><br>Login Succeeded<br><\/pre>\n\n\n\n<p>Now, the command will save your credentials in \/root\/, however that folder doesn&#8217;t persist in unraid, so this won&#8217;t persist between reboots. To do that, we have to go to the go script (\/boot\/config\/go). We want to add the line below to the go script (note the single quotes around the password for special characters to work)<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">docker login -u xxxxxx -p 'xxxxxx'<\/pre>\n\n\n\n<p>This worked well and I now have double the image pulls to burn through on my unraid server. I&#8217;m glad to be able to try out new software sooner rather than waiting a day for the limits to reset.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve had a few times now where I can&#8217;t grab a new container image to startup due to their rates limits on docker hub. This has been quite annoying, and there is a free plan for double the image pulls. Here is how you can login on unraid and setup the go file so it &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/lab.rapternet.us\/?p=3300\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Docker Hub Login on Unraid&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":3297,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[13,14,15],"class_list":["post-3300","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-how-to","tag-docker","tag-quick-bites","tag-unraid"],"_links":{"self":[{"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/posts\/3300","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3300"}],"version-history":[{"count":5,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/posts\/3300\/revisions"}],"predecessor-version":[{"id":3306,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/posts\/3300\/revisions\/3306"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=\/wp\/v2\/media\/3297"}],"wp:attachment":[{"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3300"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3300"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lab.rapternet.us\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3300"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}