Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
infra
ansible-shared
common
Commits
2e9f8bb7
Commit
2e9f8bb7
authored
6 years ago
by
Robin Sonnabend
Browse files
Options
Downloads
Patches
Plain Diff
Replace ansible_distribution_release by debian_version
parent
bc9e8b4f
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
apt/tasks/repositories.yml
+5
-5
5 additions, 5 deletions
apt/tasks/repositories.yml
ssh-server/tasks/main.yml
+2
-2
2 additions, 2 deletions
ssh-server/tasks/main.yml
with
7 additions
and
7 deletions
apt/tasks/repositories.yml
+
5
−
5
View file @
2e9f8bb7
...
...
@@ -5,7 +5,7 @@
-
name
:
enable debian repositories
apt_repository
:
state
:
present
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
ansible_distribution_release
}}{{
item[1]
}}
{{
item[0]
}}"
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
debian_version
}}{{
item[1]
}}
{{
item[0]
}}"
with_nested
:
-
"
{{
apt_repos
}}"
-
"
{{
apt_sets|union([''])|unique
}}"
...
...
@@ -18,7 +18,7 @@
-
name
:
disable debian repositories unused sets
apt_repository
:
state
:
absent
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
ansible_distribution_release
}}{{
item[1]
}}
{{
item[0]
}}"
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
debian_version
}}{{
item[1]
}}
{{
item[0]
}}"
with_nested
:
-
"
{{
apt_repos
}}"
-
"
{{
['',
'-updates',
'-backports',
'-proposed-updates']|difference(apt_sets|union(['']))
}}"
...
...
@@ -31,7 +31,7 @@
-
name
:
disable debian repositories unused repos
apt_repository
:
state
:
absent
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
ansible_distribution_release
}}{{
item[1]
}}
{{
item[0]
}}"
repo
:
"
deb{{
src
}}
{{
apt_mirror
}}
{{
debian_version
}}{{
item[1]
}}
{{
item[0]
}}"
with_nested
:
-
"
{{
['main',
'contrib',
'non-free']|difference(apt_repos)
}}"
-
[
'
'
,
'
-updates'
,
'
-backports'
,
'
-proposed-updates'
]
...
...
@@ -44,7 +44,7 @@
-
name
:
enable debian security repositories
apt_repository
:
state
:
present
repo
:
"
deb{{
src
}}
{{
apt_mirror_security
}}
{{
ansible_distribution_release
}}{{
item[1]
}}
{{
item[0]
}}"
repo
:
"
deb{{
src
}}
{{
apt_mirror_security
}}
{{
debian_version
}}{{
item[1]
}}
{{
item[0]
}}"
with_nested
:
-
"
{{
apt_repos
}}"
-
[
'
/updates'
]
...
...
@@ -58,7 +58,7 @@
-
name
:
disable debian security repositories unused repos
apt_repository
:
state
:
absent
repo
:
"
deb{{
src
}}
{{
apt_mirror_security
}}
{{
ansible_distribution_release
}}{{
item[1]
}}
{{
item[0]
}}"
repo
:
"
deb{{
src
}}
{{
apt_mirror_security
}}
{{
debian_version
}}{{
item[1]
}}
{{
item[0]
}}"
with_nested
:
-
"
{{
['main',
'contrib',
'non-free']|difference(apt_repos)
}}"
-
[
'
/updates'
]
...
...
This diff is collapsed.
Click to expand it.
ssh-server/tasks/main.yml
+
2
−
2
View file @
2e9f8bb7
...
...
@@ -17,7 +17,7 @@
mode
:
'
0644'
backup
:
true
validate
:
'
/usr/sbin/sshd
-t
-f
%s'
when
:
ansible_distribution_release != "stretch
"
when
:
debian_version == "jessie
"
notify
:
-
restart sshd
tags
:
...
...
@@ -32,7 +32,7 @@
mode
:
'
0644'
backup
:
true
validate
:
'
/usr/sbin/sshd
-t
-f
%s'
when
:
ansible_distribution_release == "stretch
"
when
:
debian_version != "jessie
"
notify
:
-
restart sshd
tags
:
...
...
This diff is collapsed.
Click to expand it.
Lars Beckers
@larsb
mentioned in merge request
!8 (merged)
·
4 years ago
mentioned in merge request
!8 (merged)
mentioned in merge request !8
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment