Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'SLE-12-SP2-CASP' into add-minimalistic-libzypp-config-m…
…aster * SLE-12-SP2-CASP: Add log message when zypp.conf is adapted Adjust tests to zypp.conf augeas handling minimalistic_configuration -> minimalistic_libzypp_config Fix ProductFeatures.GetBooleanFeature reference Add zypp_conf.rb file to package Add a flag to control libzypp minimalistic config Add a writing example for CFA::ZyppConf class Update Travis dependencies Add augeas-lenses dependency Drop ZyppConf module Add a pretty minimal test for ZyppConf class Use CFA to handle /etc/zypp/zypp.conf packaging using sed to write zypp.conf in the installed system instead of copying packaging copy zypp.conf from inst_sys to target_system
- Loading branch information
Showing
8 changed files
with
1,352 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
require "cfa/base_model" | ||
require "cfa/augeas_parser" | ||
require "cfa/matcher" | ||
|
||
module Yast | ||
module Packager | ||
module CFA | ||
# Represents a Zypper configuration file. | ||
class ZyppConf < ::CFA::BaseModel | ||
# Configuration parser | ||
PARSER = ::CFA::AugeasParser.new("puppet.lns") | ||
# Path to configuration file | ||
PATH = "/etc/zypp/zypp.conf".freeze | ||
|
||
def initialize(file_handler: nil) | ||
super(PARSER, PATH, file_handler: file_handler) | ||
end | ||
|
||
# Set options to keep a minimalistic package selection | ||
def set_minimalistic! | ||
data["main"]["solver.onlyRequires"] = "true" | ||
data["main"]["rpm.install.excludedocs"] = "yes" | ||
data["main"]["multiversion"] = nil | ||
end | ||
|
||
def section(name) | ||
data[name] | ||
end | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.