<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">Hello, <br>
      <br>
      I'm adding back the mailing list in CC<br>
      <br>
      There is no easy way to display on the main page if nodes need
      upgrade or not, because it's not really the "Rudder-way".<br>
      <br>
      In Rudder, you define Rules which define a state (package is
      installed, service is running, user is there with specific
      password, specific ssh key, and so on)<br>
      Rudder will automatically try to fix any non-conformity (we are
      implementing a check-only mode, to check without correcting), and
      reports on the compliance of the rules (rules is successfully
      applied, or Rudder needed to repair something, or Rudder failed to
      repair something). <br>
      <br>
      <br>
      If you want to know if updates are available, you could create
      your own technique (with the Technique editor) that would execute
      the following command<br>
      /bin/sh -c '! /usr/bin/apt-get -s upgrade | /bin/grep -q Inst'<br>
      <br>
      It would simulate an upgrade, and check if any lines match the
      "Inst" output, if so, return exit code of 1 (considered an error),
      else exit code 0 <br>
      <br>
      Then, you'll need to create a Directive based on this Technique,
      and create a Rule (or modify a Rule) to apply this directive)<br>
      You'll have error reports from node which don't have packages up
      to date<br>
      <br>
      Nicolas<br>
      <br>
      <br>
      Le 21/08/2015 14:52, Anak So a écrit :<br>
    </div>
    <blockquote cite="mid:SNT153-W404843788B7BC7101CB14EA9650@phx.gbl"
      type="cite">
      <style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style>
      <div dir="ltr">Hello,
        <div><br>
        </div>
        <div>Thank you for replying so quickly,</div>
        <div><br>
        </div>
        <div>It's work Thank you ! But i had one more question, i would
          like to know if it's possible to have a display on the main
          page who shows if my nodes need to be upgrade or not.</div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>Best regards,<br>
          <br>
          <div>
            <hr id="stopSpelling">Date: Fri, 21 Aug 2015 09:35:55 +0200<br>
            From: <a class="moz-txt-link-abbreviated" href="mailto:nicolas.charles@normation.com">nicolas.charles@normation.com</a><br>
            To: <a class="moz-txt-link-abbreviated" href="mailto:anak27@outlook.fr">anak27@outlook.fr</a>; <a class="moz-txt-link-abbreviated" href="mailto:rudder-users@lists.rudder-project.org">rudder-users@lists.rudder-project.org</a><br>
            Subject: Re: [rudder-users] Mettre à jours tous les packages<br>
            <br>
            <div class="ecxmoz-cite-prefix">Hello,<br>
              <br>
              This is an english speaking mailing list, so I'll answer
              in english (with the french version below)<br>
              You are trying to upgrade automatically all packages with
              the Technique Package management for Debian/Ubuntu/APT
              systems. However, this technique is made to upgrade only
              package per package. <br>
              You tried with Job scheduler to execute "apt-get upgrade",
              but it also failed.<br>
              When using Job scheduler to execute a command, you should
              give it the full path to the binary, so the command would
              need to be /usr/bin/apt-get upgrade<br>
              This would however still fail, as apt-get upgrade needs a
              user input...<br>
              <br>
              To prevent apt from asking questions, environnement and
              options need to be configured. The command would need to
              be<br>
              "/usr/bin/env DEBIAN_FRONTEND=noninteractive LC_ALL=C
              /usr/bin/apt-get -o Dpkg::Options::=--force-confold -o
              Dpkg::Options::=--force-confdef -o <a
                moz-do-not-send="true" class="ecxmoz-txt-link-freetext"
                target="_blank">APT::Get::AutomaticRemove=false</a>
              --yes upgrade"<br>
              (don't put the " " in the field)<br>
              <br>
              Does that fix your issue ?<br>
              <br>
              -------<br>
              French version<br>
              <br>
              Bonjour,<br>
              <br>
              Cette mailing liste est une mailing liste en langue
              anglaise, donc la réponse principale est en anglais (avec
              la traduction ici)<br>
              <br>
              La Technique <font size="3"><span
                  style="background-color:rgb(255, 255, 255);">Package
                  management for Debian / Ubuntu / APT systems est
                  conçue pour gérer les paquets individuellement, elle
                  ne pourra donc pas mettre à jour tous les paquets
                  directement<br>
                  <br>
                  La technique Job Scheduler execute des commandes, en
                  necessitant le chemin complet vers le binaire, la
                  commande à executer serait donc "</span></font><br>
              <font size="3"><span style="background-color:rgb(255, 255,
                  255);">/usr/bin/apt-get upgrade"<br>
                  Mais cela ne fonctionnera pas, car apt-get upgrade a
                  besoin par défaut d'une confirmation dans un terminal.<br>
                  <br>
                  Il faut donc définir les parametres et options d'apt
                  pour executer l'upgrade en non interactif, et la
                  commande sera alors<br>
                </span></font><br>
              <font size="3"><span style="background-color:rgb(255, 255,
                  255);">"/usr/bin/env DEBIAN_FRONTEND=noninteractive
                  LC_ALL=C /usr/bin/apt-get -o
                  Dpkg::Options::=--force-confold -o
                  Dpkg::Options::=--force-confdef -o <a
                    moz-do-not-send="true"
                    class="ecxmoz-txt-link-freetext" target="_blank">APT::Get::AutomaticRemove=false</a>
                  --yes upgrade"<br>
                  (sans saisir les " " dans le champ)<br>
                  <br>
                  Est ce que cela corrige le problème ?<br>
                  <br>
                  Cordialement<br>
                  Nicolas<br>
                  <br>
                </span></font>Le 20/08/2015 15:46, Anak So a écrit :<br>
            </div>
            <blockquote
              cite="mid:SNT153-W72090452D0AB5CA15A7F9FA9660@phx.gbl">
              <style><!--
.ExternalClass .ecxhmmessage P {
padding:0px;
}

.ExternalClass body.ecxhmmessage {
font-size:12pt;
font-family:Calibri;
}

--></style>
              <div dir="ltr"><font size="3">Bonjour,</font>
                <div><font size="3"><br>
                  </font></div>
                <div><font size="3">J'ai récemment installé Rudder afin
                    d'automatiser les mise à jours de plusieurs VM
                    Ubuntu mais je ne parviens pas à savoir comment cela
                    se configure, car suite à plusieurs recherche j'ai
                    constaté qu'il existait une directive appelée  <span
                      style="background-color:rgb(255, 255, 255);">Package
                      management for Debian / Ubuntu / APT systems </span>mais
                    qui ne met à jour qu'un type de package. Existe t-il
                    un moyen pour mettre à jour tous les packages  ? Si
                    oui comment ?</font></div>
                <div><font size="3"><br>
                  </font></div>
                <div><font size="3">De plus j'ai aussi essayé de
                    configurer la directive <span
                      style="background-color:rgb(255, 255, 255);">J</span><span
                      style="background-color:rgb(255, 255, 255);">ob
                      scheduler, en y ajoutant comme commande "apt-get
                      upgrade" en espérant que cela lance la commande
                      automatiquement mais cela reste un </span>échec.</font></div>
                <div><font size="2"><br>
                  </font></div>
                <div>Merci,</div>
                <div><font size="2" face="Tahoma, Geneva, Arial,
                    Helvetica, sans-serif"><br>
                  </font></div>
                <div><font size="2" face="Tahoma, Geneva, Arial,
                    Helvetica, sans-serif"><br>
                  </font></div>
                <div><font size="2" face="Tahoma, Geneva, Arial,
                    Helvetica, sans-serif"><br>
                  </font></div>
              </div>
              <br>
              <fieldset class="ecxmimeAttachmentHeader"></fieldset>
              <br>
              <pre>_______________________________________________
rudder-users mailing list
<a moz-do-not-send="true" class="ecxmoz-txt-link-abbreviated" href="mailto:rudder-users@lists.rudder-project.org">rudder-users@lists.rudder-project.org</a>
<a moz-do-not-send="true" class="ecxmoz-txt-link-freetext" href="http://www.rudder-project.org/mailman/listinfo/rudder-users" target="_blank">http://www.rudder-project.org/mailman/listinfo/rudder-users</a>
</pre>
            </blockquote>
            <br>
            <br>
            <pre class="ecxmoz-signature">-- 
Nicolas CHARLES</pre>
          </div>
        </div>
      </div>
    </blockquote>
    <br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Nicolas CHARLES</pre>
  </body>
</html>