Skip to content

Commit

Permalink
Merge pull request #920 from carabasdaniel/rollback_permissions
Browse files Browse the repository at this point in the history
(MODULES-10583) Revert "MODULES-10548: make files readonly"
  • Loading branch information
DavidS authored Mar 10, 2020
2 parents ed1706d + 316fd8f commit ba65bec
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
10 changes: 5 additions & 5 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
path => $::apt::sources_list,
owner => root,
group => root,
mode => '0444',
mode => '0644',
notify => Class['apt::update'],
}

Expand All @@ -239,7 +239,7 @@
path => $::apt::sources_list_d,
owner => root,
group => root,
mode => '0555',
mode => '0644',
purge => $_purge['sources.list.d'],
recurse => $_purge['sources.list.d'],
notify => Class['apt::update'],
Expand All @@ -250,7 +250,7 @@
path => $::apt::preferences,
owner => root,
group => root,
mode => '0444',
mode => '0644',
notify => Class['apt::update'],
}

Expand All @@ -259,7 +259,7 @@
path => $::apt::preferences_d,
owner => root,
group => root,
mode => '0555',
mode => '0644',
purge => $_purge['preferences.d'],
recurse => $_purge['preferences.d'],
notify => Class['apt::update'],
Expand Down Expand Up @@ -308,7 +308,7 @@
ensure => $auth_conf_ensure,
owner => $auth_conf_owner,
group => 'root',
mode => '0400',
mode => '0600',
content => "${confheadertmp}${auth_conf_tmp}",
notify => Class['apt::update'],
}
Expand Down
2 changes: 1 addition & 1 deletion manifests/setting.pp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
ensure => $ensure,
owner => 'root',
group => 'root',
mode => '0444',
mode => '0644',
content => $content,
source => $source,
notify => $_notify,
Expand Down
12 changes: 6 additions & 6 deletions spec/classes/apt_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
path: '/etc/apt/sources.list',
owner: 'root',
group: 'root',
mode: '0444',
mode: '0644',
notify: 'Class[Apt::Update]' }

sources_list_d = { ensure: 'directory',
path: '/etc/apt/sources.list.d',
owner: 'root',
group: 'root',
mode: '0555',
mode: '0644',
purge: false,
recurse: false,
notify: 'Class[Apt::Update]' }
Expand All @@ -20,14 +20,14 @@
path: '/etc/apt/preferences',
owner: 'root',
group: 'root',
mode: '0444',
mode: '0644',
notify: 'Class[Apt::Update]' }

preferences_d = { ensure: 'directory',
path: '/etc/apt/preferences.d',
owner: 'root',
group: 'root',
mode: '0555',
mode: '0644',
purge: false,
recurse: false,
notify: 'Class[Apt::Update]' }
Expand Down Expand Up @@ -76,7 +76,7 @@

it 'lays down /etc/apt/apt.conf.d/15update-stamp' do
is_expected.to contain_file('/etc/apt/apt.conf.d/15update-stamp').with(group: 'root',
mode: '0444',
mode: '0644',
owner: 'root').with_content(
%r{APT::Update::Post-Invoke-Success {"touch /var/lib/apt/periodic/update-success-stamp 2>/dev/null || true";};},
)
Expand Down Expand Up @@ -301,7 +301,7 @@
is_expected.to contain_file('/etc/apt/auth.conf').with(ensure: 'present',
owner: auth_conf_owner,
group: 'root',
mode: '0400',
mode: '0600',
notify: 'Class[Apt::Update]',
content: auth_conf_content)
}
Expand Down
4 changes: 2 additions & 2 deletions spec/defines/conf_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
'content' => %r{Apt::Install-Recommends 0;\nApt::AutoRemove::InstallRecommends 1;},
'owner' => 'root',
'group' => 'root',
'mode' => '0444')
'mode' => '0644')
}

context 'with notify_update = true (default)' do
Expand Down Expand Up @@ -83,7 +83,7 @@
is_expected.to contain_file(filename).with('ensure' => 'absent',
'owner' => 'root',
'group' => 'root',
'mode' => '0444')
'mode' => '0644')
}
end
end
4 changes: 2 additions & 2 deletions spec/defines/setting_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
is_expected.to contain_file('/etc/apt/apt.conf.d/50teddybear').that_notifies('Class[Apt::Update]').with(ensure: 'file',
owner: 'root',
group: 'root',
mode: '0444',
mode: '0644',
source: params[:source].to_s)
}
end
Expand All @@ -62,7 +62,7 @@
is_expected.to contain_file('/etc/apt/apt.conf.d/50teddybear').that_notifies('Class[Apt::Update]').with(ensure: 'file',
owner: 'root',
group: 'root',
mode: '0444',
mode: '0644',
content: params[:content].to_s)
}
end
Expand Down

0 comments on commit ba65bec

Please sign in to comment.