{"id":793,"date":"2012-09-07T15:27:34","date_gmt":"2012-09-07T15:27:34","guid":{"rendered":"http:\/\/www.cloudcomp.ch\/?p=793"},"modified":"2012-09-07T15:27:34","modified_gmt":"2012-09-07T15:27:34","slug":"installing-foreman-1-0-1","status":"publish","type":"post","link":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/","title":{"rendered":"Installing Foreman 1.0.1"},"content":{"rendered":"<p>Just recently the Foreman project released the latest version, 1.0.1. If you are following our [previous guide to install 0.4.2](http:\/\/www.cloudcomp.ch\/2012\/06\/automating-the-icclab-part-one\/) then you should also follow this.<\/p>\n<p># Installing &amp; Configuring Foreman<br \/>\nYou should setup your virtual machine exactly as we did in the previous guide, install puppet and checkout the foreman-installer modules from github. There is a small number of issues with the installer but we&#8217;ll easily walk you through them!<\/p>\n<p>To check things out quickly, you can [download a VM (OVA) that has Foreman 1.0.1](http:\/\/www.cloudcomp.ch\/wp-content\/uploads\/2012\/09\/Foreman1.01.ova) preconfigured. The username\/password is `root` and `root`. This also includes puppet modules to deploy OpenStack compute and controller nodes.<\/p>\n<p>&gt; Side note: the puppetlabs repository has changed. Make sure to:<br \/>\n&gt; `wget http:\/\/apt.puppetlabs.com\/puppetlabs-release-stable.deb`<\/p>\n<p>Ensure that the foreman-proxy is part of the bind group. If not add the user:<\/p>\n<p>[gist id=3667157]<\/p>\n<p>Configure your `foreman_proxy\/manifests\/params.pp as` before, ensuring to enable DHCP and DNS and for each of those setting the correct network settings (subnet etc)<\/p>\n<p>Configure you `foreman\/manifest\/params.pp` as before. For us we disabled SSL. Very important here is that you set the `foreman_url` parameter to include the port number on which foreman listens (port 3000). <\/p>\n<p>[gist id=3667152]<\/p>\n<p>If it is not set then the scripts that tie puppet and foreman together will not work. This is a [known and reported issue](http:\/\/theforeman.org\/issues\/1855), which will be resolved.<\/p>\n<p>Currently there is a bug in `foreman_proxy\/manifests\/proxydhcp.pp`. For now you need to manually set the DNS `nameserver` and TFTP `nextserver` parameters. This [bug has been reported](https:\/\/groups.google.com\/d\/topic\/foreman-users\/t1m8JeWVd7U\/discussion) and will be resolved soon.<\/p>\n<p>Finally you need to apply [this patch](https:\/\/github.com\/theforeman\/smart-proxy\/commit\/a402c71290f2d8205e60b876f2a40dfa9fefacda). Puppet in its most recent version changed the value of the return code from operations related to `puppetca`. This causes blocking issues with provisioning and deleting hosts with foreman. You can use this sed command if it suits you:<\/p>\n<p>[gist id=3667151]<\/p>\n<p>Once applied you should restart the foreman-proxy service<\/p>\n<p>[gist id=3667147]<\/p>\n<p>Note, if you start the foreman service and it halts with a stacktrace then you will have to reinitialise the database. This is a one-time operation.<\/p>\n<p>[gist id=3667139]<\/p>\n<p>Once these step have been complete, you can then configure Foreman itself (setting smart proxy, host groups etc).<\/p>\n<p>When configuring these various aspects you should update the &#8216;Ubuntu default&#8217; disk partition table configuration. Use the following to ensure a complete automatic install:<\/p>\n<p>[gist id=3667133]<\/p>\n<p>One of the issues that we&#8217;re dealing with currently is that rather than the puppetmaster&#8217;s hostname being placed in the relevant configuration files (e.g. `puppet.conf`), an IP address is inserted. This will not work as it will fail with SSL issues. The current work around is to create a &#8216;snippet&#8217; in the Provisioning Templates section. With this snippet created then set the content of the config files in Provisioning Templates to (using `puppet.conf` as an examples):<\/p>\n<p>[gist id=3667127]<\/p>\n<div class=\"pt-sm\">Schlagw\u00f6rter: <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/automation\/\">automation<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/baremetal\/\">baremetal<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/foreman\/\">foreman<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/guide\/\">guide<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/howto\/\">howto<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/infrastructure\/\">infrastructure<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/install\/\">install<\/a>, <a href=\"https:\/\/blog.zhaw.ch\/icclab\/tag\/puppet\/\">puppet<\/a><br><\/div>","protected":false},"excerpt":{"rendered":"<p>Just recently the Foreman project released the latest version, 1.0.1. If you are following our previous guide to install 0.4.2 then you should follow this.<\/p>\n","protected":false},"author":72,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"footnotes":""},"categories":[5],"tags":[51,54,148,169,181,192,195,271],"features":[],"class_list":["post-793","post","type-post","status-publish","format-standard","hentry","category-articles","tag-automation","tag-baremetal","tag-foreman","tag-guide","tag-howto","tag-infrastructure","tag-install","tag-puppet"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Installing Foreman 1.0.1 - Service Engineering (ICCLab &amp; SPLab)<\/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:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Installing Foreman 1.0.1\" \/>\n<meta property=\"og:description\" content=\"Just recently the Foreman project released the latest version, 1.0.1. If you are following our previous guide to install 0.4.2 then you should follow this.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\" \/>\n<meta property=\"og:site_name\" content=\"Service Engineering (ICCLab &amp; SPLab)\" \/>\n<meta property=\"article:published_time\" content=\"2012-09-07T15:27:34+00:00\" \/>\n<meta name=\"author\" content=\"Andy Edmonds\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Andy Edmonds\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\"},\"author\":{\"name\":\"Andy Edmonds\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684\"},\"headline\":\"Installing Foreman 1.0.1\",\"datePublished\":\"2012-09-07T15:27:34+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\"},\"wordCount\":525,\"commentCount\":3,\"keywords\":[\"automation\",\"baremetal\",\"foreman\",\"guide\",\"howto\",\"infrastructure\",\"install\",\"puppet\"],\"articleSection\":[\"Articles\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\",\"url\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\",\"name\":\"Installing Foreman 1.0.1 - Service Engineering (ICCLab &amp; SPLab)\",\"isPartOf\":{\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/#website\"},\"datePublished\":\"2012-09-07T15:27:34+00:00\",\"author\":{\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684\"},\"breadcrumb\":{\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Startseite\",\"item\":\"https:\/\/blog.zhaw.ch\/icclab\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Installing Foreman 1.0.1\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/#website\",\"url\":\"https:\/\/blog.zhaw.ch\/icclab\/\",\"name\":\"Service Engineering (ICCLab &amp; SPLab)\",\"description\":\"A Blog of the ZHAW Zurich University of Applied Sciences\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/blog.zhaw.ch\/icclab\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684\",\"name\":\"Andy Edmonds\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g\",\"caption\":\"Andy Edmonds\"},\"sameAs\":[\"http:\/\/andy.edmonds.be\"],\"url\":\"https:\/\/blog.zhaw.ch\/icclab\/author\/edmo\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Installing Foreman 1.0.1 - Service Engineering (ICCLab &amp; SPLab)","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:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/","og_locale":"en_US","og_type":"article","og_title":"Installing Foreman 1.0.1","og_description":"Just recently the Foreman project released the latest version, 1.0.1. If you are following our previous guide to install 0.4.2 then you should follow this.","og_url":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/","og_site_name":"Service Engineering (ICCLab &amp; SPLab)","article_published_time":"2012-09-07T15:27:34+00:00","author":"Andy Edmonds","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Andy Edmonds","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#article","isPartOf":{"@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/"},"author":{"name":"Andy Edmonds","@id":"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684"},"headline":"Installing Foreman 1.0.1","datePublished":"2012-09-07T15:27:34+00:00","mainEntityOfPage":{"@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/"},"wordCount":525,"commentCount":3,"keywords":["automation","baremetal","foreman","guide","howto","infrastructure","install","puppet"],"articleSection":["Articles"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/","url":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/","name":"Installing Foreman 1.0.1 - Service Engineering (ICCLab &amp; SPLab)","isPartOf":{"@id":"https:\/\/blog.zhaw.ch\/icclab\/#website"},"datePublished":"2012-09-07T15:27:34+00:00","author":{"@id":"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684"},"breadcrumb":{"@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/blog.zhaw.ch\/icclab\/installing-foreman-1-0-1\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Startseite","item":"https:\/\/blog.zhaw.ch\/icclab\/"},{"@type":"ListItem","position":2,"name":"Installing Foreman 1.0.1"}]},{"@type":"WebSite","@id":"https:\/\/blog.zhaw.ch\/icclab\/#website","url":"https:\/\/blog.zhaw.ch\/icclab\/","name":"Service Engineering (ICCLab &amp; SPLab)","description":"A Blog of the ZHAW Zurich University of Applied Sciences","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/blog.zhaw.ch\/icclab\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/blog.zhaw.ch\/icclab\/#\/schema\/person\/a62f7b702361e11d635f4e59446e8684","name":"Andy Edmonds","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/564b17a1126a2ed30e20d4c65842164e32a6cf798a8175e88bcf5b352ebd60c8?s=96&d=mm&r=g","caption":"Andy Edmonds"},"sameAs":["http:\/\/andy.edmonds.be"],"url":"https:\/\/blog.zhaw.ch\/icclab\/author\/edmo\/"}]}},"_links":{"self":[{"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/posts\/793","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/users\/72"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/comments?post=793"}],"version-history":[{"count":0,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/posts\/793\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/media?parent=793"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/categories?post=793"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/tags?post=793"},{"taxonomy":"features","embeddable":true,"href":"https:\/\/blog.zhaw.ch\/icclab\/wp-json\/wp\/v2\/features?post=793"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}