Sha256: 3bdca595cc21a0020a7e5a2ff0b9275321432828bc8375c9e72309612fdb32d4
Contents?: true
Size: 561 Bytes
Versions: 7
Compression:
Stored size: 561 Bytes
Contents
module Pvcglue class Packages class AptUpgrade < Pvcglue::Packages def installed? # TODO: Add a "force" option updated_at = get_minion_state(:apt_upgraded_at) return false unless updated_at # updated_at > Time.now.utc - 8.hours # TODO: Give the user a warning after a period of time true end def install! minion.connection.run!(:root, '', 'DEBIAN_FRONTEND=noninteractive apt-get upgrade -y') set_minion_state(:apt_upgraded_at, Time.now.utc) end end end end
Version data entries
7 entries across 7 versions & 1 rubygems