
{"id":32,"date":"2014-03-22T23:55:33","date_gmt":"2014-03-22T12:55:33","guid":{"rendered":"http:\/\/mnm.at\/markus\/?p=32"},"modified":"2014-04-05T11:53:05","modified_gmt":"2014-04-05T00:53:05","slug":"autoyast-for-opensuse-123","status":"publish","type":"post","link":"https:\/\/mnm.at\/markus\/2014\/03\/22\/autoyast-for-opensuse-123\/","title":{"rendered":"autoyast for opensuse  12.3"},"content":{"rendered":"<h3>shaving the yast<\/h3>\n<p>So I wanted to have a play with <a href=\"http:\/\/www.packer.io\">packer<\/a> but decided to have a look at autoyast while I am at it.<\/p>\n<p>OpenSuSE 12.3 has a bug [BNC#801878] though that prevent the network and ssh to be started up.<\/p>\n<p>And it seems the <keep_install_network> does not work as expected either since if always shut it down, or with updates enabled created an additional interface.<\/p>\n<p>ended up not caring about the package updates (since the vagrant box would be outdated anyway) and instead doing this:<\/p>\n<pre><code> &lt;noscripts&gt;\n    &lt;chroot-scripts config:type=\"list\"&gt;\n      &lt;noscript&gt;\n        &lt;!&amp;#8212; FIXING BNC#801878 &amp;#8212;&gt;\n        &lt;filename&gt;chroot_bugfixing_801878.sh&lt;\/filename&gt;\n        &lt;source&gt;&lt;![CDATA[#!\/bin\/bash\n        #Fix ag_initscripts according to BNC#801878\n        sed -i &amp;#39;s\/.&lt;strong&gt;(\/sbin\/runlevel.&lt;\/strong&gt;)\/SYSTEMCTL_OPTIONS=\"\" 1\/&amp;#39; \/mnt\/usr\/lib\/YaST2\/servers_non_y2\/ag_initscripts\n        ]]&gt;\n        &lt;\/source&gt;\n      &lt;\/noscript&gt;\n    &lt;\/chroot-scripts&gt;\n    &lt;postpartitioning-scripts config:type=\"list\"&gt;\n      &lt;noscript&gt;\n        &lt;filename&gt;ssh_key_installation.sh&lt;\/filename&gt;\n        &lt;source&gt;&lt;![CDATA[#!\/bin\/bash\n         # Evaluate the http server IP PORT to retrieve the ssh key and then set it up\n         httpServer=$( grep AutoYaST \/etc\/install.inf | sed &amp;#39;s~.&lt;strong&gt;(http:\/\/.&lt;\/strong&gt;\/).*~1~&amp;#39; )\n         httpUrl=\"${httpServer}\/id_rsa_packer_images.pub\"\n\n         rootSsh=\/mnt\/root\/.ssh\n         mkdir -p ${rootSsh}\n         wget \"${httpUrl}\" -O ${rootSsh}\/authorized_keys\n         chmod -R og-rwx ${rootSsh}\n\n         verpackerSsh=\/mnt\/home\/verpacker\/.ssh\n         mkdir -p ${verpackerSsh}\n         wget \"${httpUrl}\" -O ${verpackerSsh}\/authorized_keys\n         chmod -R og-rwx ${verpackerSsh}\n         chown -R 1000:100 \/mnt\/home\/verpacker        \n         ]]&gt;\n        &lt;\/source&gt;\n      &lt;\/noscript&gt;         \n    &lt;\/postpartitioning-scripts&gt;\n    &lt;post-scripts config:type=\"list\"&gt;\n      &lt;noscript&gt;\n        &lt;filename&gt;post_script_no_network_shutdown.sh&lt;\/filename&gt;\n        &lt;source&gt;&lt;![CDATA[#!\/bin\/bash\n        # preventing the shut down of the network at the end of the installation\n        sed -i &amp;#39;s~(.*rcnetwork .*stop)~# removed by post_script_no_network_shutdown 1~&amp;#39; \/usr\/lib\/YaST2\/startup\/Second-Stage\/S09-cleanup\n        ]]&gt;\n        &lt;\/source&gt;\n      &lt;\/noscript&gt;\n    &lt;\/post-scripts&gt;    \n  &lt;\/noscripts&gt;\n<\/code><\/pre>\n<p>ok, the ssh-key is for packer and not the network issues.<\/p>\n<p>Packer : ~1 evening autoyast : ~5 evenings<\/p>\n<p>I also decided to become a more sharing person :<\/p>\n<p>https:\/\/bitbucket.org\/markus_ebenhoeh\/packer-opensuse.12.3<\/p>\n","protected":false},"excerpt":{"rendered":"<p>How playing with packer become Shaving the Yast2<br \/>\nsource at https:\/\/bitbucket.org\/markus_ebenhoeh\/packer-opensuse.12.3 <a href=\"https:\/\/mnm.at\/markus\/2014\/03\/22\/autoyast-for-opensuse-123\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":6,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"categories":[5],"tags":[6,7,8],"class_list":["post-32","post","type-post","status-publish","format-standard","hentry","category-tech","tag-linux","tag-opensuse","tag-yast"],"_links":{"self":[{"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/posts\/32","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/comments?post=32"}],"version-history":[{"count":1,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/posts\/32\/revisions"}],"predecessor-version":[{"id":33,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/posts\/32\/revisions\/33"}],"wp:attachment":[{"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/media?parent=32"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/categories?post=32"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mnm.at\/markus\/wp-json\/wp\/v2\/tags?post=32"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}