Browse Source
Keep sources.list even if remove_sources_list set
Deleting the file causes "could not open file '/etc/apt/sources.list'"
warnings. Better to keep it around but just remove its contents.
master
Adam Bolte
8 years ago
No account linked to committer's email address
1 changed files with
3 additions and
3 deletions
-
apt/repositories.sls
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/etc/apt/sources.list: |
|
|
/etc/apt/sources.list: |
|
|
file.managed: |
|
|
file.managed: |
|
|
{%- if remove_sources_list %} |
|
|
|
|
|
- contents: '' |
|
|
|
|
|
{%- else %} |
|
|
|
|
|
- mode: '0644' |
|
|
- mode: '0644' |
|
|
- user: root |
|
|
- user: root |
|
|
- group: root |
|
|
- group: root |
|
|
|
|
|
{% if remove_sources_list %} |
|
|
|
|
|
- contents: '' |
|
|
|
|
|
- contents_newline: False |
|
|
{% endif %} |
|
|
{% endif %} |
|
|
|
|
|
|
|
|
{{ sources_list_dir }}: |
|
|
{{ sources_list_dir }}: |