1. 25 Jun, 2009 4 commits
  2. 24 Jun, 2009 1 commit
    • lxc-fedora fixes · 4f3f0d4b
      Matty authored
      Howdy,
      
      I was playing around with LXC containers this past weekend, and
      noticed a couple of issues with the lxc-fedora script:
      
      #1: Line 96 should be ${ROOTFS}/etc/sysconfig/network instead of
      ${ROOTFS}/sysconfig/network
      
      #2 Line 249 contains a reference to $PKG, which isn't used in the
      program. I adjusted the variable to point to the correct package, and
      use this in the calls to yumdownloader:
      
          PKG="${DISTRO}-release.noarch.rpm"
                         .....
          yumdownloader --destdir="${CACHE}/partial" "${PKG}"
      
      #3 The $CACHE/partial path is escaped unnecessarily:
      
         RPM="rpm --root \"${CACHE}/partial\""
      
      #4 The program assumes yumdownloader will work, which isn't always the
      case. I added an if statement to check the return code:
      
      
         echo "Downloading distribution release file ${PKG}"
         yumdownloader --destdir="${CACHE}/partial" "${PKG}"
         RESULT=$?
      
         if [ "${RESULT}" != "0" ]; then
             echo "Enable to download the distribution release file"
             exit 1
         fi
      
      #5 The package name passed to yumdownloader is incorrect:
      
         yumdownloader --destdir="${CACHE}/partial" "${DISTRO}-release.noarch.rpm"
      
         On Fedora 10 and 11, this evaluates to:
      
         fedora-release.noarch.rpm
      
         When we need it to evaluate to:
      
         fedora-{RELEASE_VER}.release.noarch
      
         This is fixed in the PKG variable listed above.
      
      A patch that addresses these issues is attached.
      
      Thanks,
      - Ryan
      Signed-off-by: 's avatarMatty <matty91@gmail.com>
      Signed-off-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com>
  3. 12 Jun, 2009 2 commits
  4. 10 Jun, 2009 5 commits
  5. 07 Jun, 2009 6 commits
  6. 29 May, 2009 1 commit
  7. 28 May, 2009 17 commits
  8. 18 May, 2009 4 commits