On 14.02.2012 20:31, Hans-Joachim Ehlers wrote:
Thus the question: How do i enable the option "--no-recommends" in autoyast by default ?
unfortunately that's not so easy That would require autoyast to run over all available packages and set a so called SoftLock. That's too expensive. For patterns autoyast can do that but not for packages.
If you use SLES11 SP2 and/or openSUSE 12.1 there might be a funny workaround that I did not try myself but might work. You can create a file in a pre-script:
<pre-scripts config:type="list"> <script> <interpreter>shell</interpreter> <source><![CDATA[ mkdir /etc/zypp echo "[main] solver.onlyRequires = true " > /etc/zypp/zypp.conf ]]></source>
that will turn off the recommends in the resolver. The bad thing is, the pre-script is executed too late. Zypp has already read the config then.
on openSUSE 12.1 and SLES11 SP2 you can restart yast by creating a file with a pre-script /var/lib/YaST2/restart_yast and if autoyast finds that file after the pre-script run, it'll terminate yast and restart it. So on 12.1 SLES11SP2 you can add a "touch /var/lib/YaST2/restart_yast" to your pre-script.
On SLES11 SP1 and pre-12.1 you can not go that way. The only way there is to create a driverupdate that contains the zypp.conf. That works for 12.1 and SLES11 SP2 too of course.
A third way (untested too) is to install the kdm in the post-packages section and modify the zypp.conf of the installed system with a chroot-script.
Everything I suggested here is untested by me, so I'd be glad to get feedback if it works for you :) Good luck ;)