{"id":572,"date":"2020-08-31T18:39:13","date_gmt":"2020-09-01T00:39:13","guid":{"rendered":"https:\/\/n8williams.com\/devblog\/?p=572"},"modified":"2020-08-31T18:41:09","modified_gmt":"2020-09-01T00:41:09","slug":"codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","status":"publish","type":"post","link":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","title":{"rendered":"Codeship apt-get update errors and yarn and command returned a non-zero code 100"},"content":{"rendered":"\n<p>TL\/DR: <code>apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com<\/code> (use with caution) may go a long ways in getting your build to work.<\/p>\n\n\n\n<p>Some noteworthy things after learning about the interplay between codeship, docker, ubuntu apt-get, and the yarn package. This resolution may help with issues dealing with:<\/p>\n\n\n\n<ul><li>Invalid signatures with the yarn ubuntu package.<\/li><li>Errors running apt-get update<\/li><li>Errors updating the Dockerfile for a CodeShip build<\/li><li>Dealing with CodeShip build steps updates and cached steps<\/li><\/ul>\n\n\n\n<p>For now, I&#8217;m noting my crazy sequence of realizations in reverse order<\/p>\n\n\n\n<p>A failed step on the server with CodeShip may not be very enlightening. If you see an <code>apt-get install -y &lt;some-package&gt; returned a non-zero code: 100<\/code> error, you may need to run the step locally to see the full error using<code> jet steps<\/code>.<\/p>\n\n\n\n<p>If you see the above error, it may be due to a command in your steps if the RUN command in the Dockerfile includes <code>apt-get update -y<\/code> <\/p>\n\n\n\n<p>The apt-get update may be failing because a package includes an invalid key. This may be the yarn package, spitting out <code>GPG error: https:\/\/dl.yarnpkg.com\/debian stable InRelease: The following signatures were invalid: EXPKEYSIG XXXXXXXX Yarn Packaging &lt;yarn@dan.cx&gt;<\/code>. If you add <code>apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com<\/code> this may resolve that issue. See <a href=\"https:\/\/github.com\/yarnpkg\/yarn\/issues\/7866\">https:\/\/github.com\/yarnpkg\/yarn\/issues\/7866<\/a><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>You may see a codeship error like:<br>2 errors occurred:<br><code>* (step: dependencies_X-deps) error loading services during run step: failure to build Image{ name: &quot;static.X&quot;, dockerfile: &quot;\/&lt;project-path&gt;\/docker\/app\/Dockerfile&quot;, cache: true }: The command &#039;\/bin\/sh -c apt-get update -y &nbsp; &amp;&amp; wget https:\/\/dl.google.com\/linux\/direct\/google-chrome-stable_beta_amd64.deb &nbsp; &amp;&amp; apt-get install -y .\/google-chrome-stable_beta_amd64.deb &nbsp; &amp;&amp; rm google-chrome-stable_beta_amd64.deb &nbsp; &amp;&amp; rm -rf \/var\/lib\/apt\/lists\/*&#039; returned a non-zero code: 100<\/code><br>&#8230;<\/p>\n\n\n\n<p>With codeship steps, if you edit the Dockerfile RUN command, and it is equivalent to a previous version of that RUN command, that command will be cached and may not trigger an error you expect. In this case it was more painful when trying to add a separate and new RUN command with <code>apt-get install -y libxss1<\/code> while updating the build to have a chrome install with the libXss dependency included.<\/p>\n\n\n\n<p>The ubuntu stable package may no longer work for you if you are using puppeteer in conjunction with a headless chrome browser to generate screen captures\/pdfs on a server. It can be a bit painful to locate a list of package versions for chrome on ubuntu, and sticking with stable and adding a <code>apt-get install -y libxss1<\/code> to your RUN command is one way to go. This may stem from seeing something like:<br><code>\/app\/pdf-thing\/node_modules\/puppeteer\/.local-chromium\/linux-XXXXX\/chrome-linux\/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory<\/code><\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>TL\/DR: apt-key adv &#8211;refresh-keys &#8211;keyserver keyserver.ubuntu.com (use with caution) may go a long ways in getting your build to work. Some noteworthy things after learning about the interplay between codeship, docker, ubuntu apt-get, and the yarn package. This resolution may help with issues dealing with: Invalid signatures with the yarn ubuntu package. Errors running apt-get &hellip; <a href=\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Codeship apt-get update errors and yarn and command returned a non-zero code 100&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[7,13],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.11 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages<\/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:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages\" \/>\n<meta property=\"og:description\" content=\"TL\/DR: apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com (use with caution) may go a long ways in getting your build to work. Some noteworthy things after learning about the interplay between codeship, docker, ubuntu apt-get, and the yarn package. This resolution may help with issues dealing with: Invalid signatures with the yarn ubuntu package. Errors running apt-get &hellip; Continue reading &quot;Codeship apt-get update errors and yarn and command returned a non-zero code 100&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\" \/>\n<meta property=\"og:site_name\" content=\"The Dev Pages\" \/>\n<meta property=\"article:published_time\" content=\"2020-09-01T00:39:13+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-09-01T00:41:09+00:00\" \/>\n<meta name=\"author\" content=\"Nate Admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@admin\" \/>\n<meta name=\"twitter:site\" content=\"@admin\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Nate Admin\" \/>\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:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#article\",\"isPartOf\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\"},\"author\":{\"name\":\"Nate Admin\",\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757\"},\"headline\":\"Codeship apt-get update errors and yarn and command returned a non-zero code 100\",\"datePublished\":\"2020-09-01T00:39:13+00:00\",\"dateModified\":\"2020-09-01T00:41:09+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\"},\"wordCount\":331,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757\"},\"articleSection\":[\"General Dev\",\"Ubuntu\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\",\"url\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\",\"name\":\"Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages\",\"isPartOf\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/#website\"},\"datePublished\":\"2020-09-01T00:39:13+00:00\",\"dateModified\":\"2020-09-01T00:41:09+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/n8williams.com\/devblog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Codeship apt-get update errors and yarn and command returned a non-zero code 100\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/n8williams.com\/devblog\/#website\",\"url\":\"https:\/\/n8williams.com\/devblog\/\",\"name\":\"The Dev Pages\",\"description\":\"A knowledge base for web applications development (and beyond)\",\"publisher\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/n8williams.com\/devblog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757\",\"name\":\"Nate Admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/19d7bc7602072ac846e912622704a628?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/19d7bc7602072ac846e912622704a628?s=96&d=mm&r=g\",\"caption\":\"Nate Admin\"},\"logo\":{\"@id\":\"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/image\/\"},\"sameAs\":[\"http:\/\/n8williams.com\",\"https:\/\/twitter.com\/admin\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages","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:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","og_locale":"en_US","og_type":"article","og_title":"Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages","og_description":"TL\/DR: apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com (use with caution) may go a long ways in getting your build to work. Some noteworthy things after learning about the interplay between codeship, docker, ubuntu apt-get, and the yarn package. This resolution may help with issues dealing with: Invalid signatures with the yarn ubuntu package. Errors running apt-get &hellip; Continue reading \"Codeship apt-get update errors and yarn and command returned a non-zero code 100\"","og_url":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","og_site_name":"The Dev Pages","article_published_time":"2020-09-01T00:39:13+00:00","article_modified_time":"2020-09-01T00:41:09+00:00","author":"Nate Admin","twitter_card":"summary_large_image","twitter_creator":"@admin","twitter_site":"@admin","twitter_misc":{"Written by":"Nate Admin","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#article","isPartOf":{"@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100"},"author":{"name":"Nate Admin","@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757"},"headline":"Codeship apt-get update errors and yarn and command returned a non-zero code 100","datePublished":"2020-09-01T00:39:13+00:00","dateModified":"2020-09-01T00:41:09+00:00","mainEntityOfPage":{"@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100"},"wordCount":331,"commentCount":0,"publisher":{"@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757"},"articleSection":["General Dev","Ubuntu"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#respond"]}]},{"@type":"WebPage","@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","url":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100","name":"Codeship apt-get update errors and yarn and command returned a non-zero code 100 - The Dev Pages","isPartOf":{"@id":"https:\/\/n8williams.com\/devblog\/#website"},"datePublished":"2020-09-01T00:39:13+00:00","dateModified":"2020-09-01T00:41:09+00:00","breadcrumb":{"@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/n8williams.com\/devblog\/general_dev\/codeship-apt-get-update-errors-and-yarn-and-command-returned-a-non-zero-code-100#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/n8williams.com\/devblog\/"},{"@type":"ListItem","position":2,"name":"Codeship apt-get update errors and yarn and command returned a non-zero code 100"}]},{"@type":"WebSite","@id":"https:\/\/n8williams.com\/devblog\/#website","url":"https:\/\/n8williams.com\/devblog\/","name":"The Dev Pages","description":"A knowledge base for web applications development (and beyond)","publisher":{"@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/n8williams.com\/devblog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/1c31624786b5382f1a811f0a01985757","name":"Nate Admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/19d7bc7602072ac846e912622704a628?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/19d7bc7602072ac846e912622704a628?s=96&d=mm&r=g","caption":"Nate Admin"},"logo":{"@id":"https:\/\/n8williams.com\/devblog\/#\/schema\/person\/image\/"},"sameAs":["http:\/\/n8williams.com","https:\/\/twitter.com\/admin"]}]}},"_links":{"self":[{"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/posts\/572"}],"collection":[{"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/comments?post=572"}],"version-history":[{"count":4,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/posts\/572\/revisions"}],"predecessor-version":[{"id":576,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/posts\/572\/revisions\/576"}],"wp:attachment":[{"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/media?parent=572"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/categories?post=572"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/n8williams.com\/devblog\/wp-json\/wp\/v2\/tags?post=572"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}