Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
Ansible development VM
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
GÉANT Orchestration and Automation Team
Development Playbooks
Ansible development VM
Merge requests
!10
Add marija, allow multiple SSH keys per user
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Add marija, allow multiple SSH keys per user
add-marija
into
main
Overview
0
Commits
2
Pipelines
0
Changes
2
Merged
Karel van Klink
requested to merge
add-marija
into
main
2 years ago
Overview
0
Commits
2
Pipelines
0
Changes
2
Expand
0
0
Merge request reports
Compare
main
main (base)
and
latest version
latest version
f8a5e6b7
2 commits,
2 years ago
2 files
+
33
−
16
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
roles/gap_utility_user/tasks/main.yml
+
9
−
7
Options
@@ -7,19 +7,21 @@
-
name
:
Add Linux users
ansible.builtin.user
:
name
:
"
{{
item.username
}}
"
comment
:
"
{{
item.full_name
}}
"
name
:
'
{{
item.username
}}
'
comment
:
'
{{
item.full_name
}}
'
create_home
:
yes
groups
:
sudo
append
:
yes
password
:
'
!'
# Do not allow login with a password
password_lock
:
yes
# Login with SSH key only
shell
:
"
{{
item.shell
}}
"
shell
:
'
{{
item.shell
}}
'
register
:
user_output
with_items
:
"
{{
goat_users
}}
"
with_items
:
'
{{
goat_users
}}
'
-
name
:
Add SSH key to user for logging in
ansible.posix.authorized_key
:
user
:
"
{{
item.username
}}"
key
:
"
{{
item.ssh_key
}}"
with_items
:
"
{{
goat_users
}}"
user
:
'
{{
item.0.username
}}'
key
:
'
{{
item.1
}}'
with_subelements
:
-
'
{{
goat_users
}}'
-
ssh_keys
Loading