Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
configuration
Commits
917f9ca5
Unverified
Commit
917f9ca5
authored
Feb 15, 2018
by
Nadeem Shahzad
Committed by
GitHub
Feb 15, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #4327 from edx/nadeem/security-updates-on-amazon-linux
Enable auto security updates for tools splunk machines
parents
38422464
06a58218
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
45 additions
and
1 deletions
+45
-1
playbooks/roles/security/defaults/main.yml
+3
-1
playbooks/roles/security/tasks/main.yml
+4
-0
playbooks/roles/security/tasks/security-amazon.yml
+36
-0
playbooks/roles/splunk-server/meta/main.yml
+2
-0
No files found.
playbooks/roles/security/defaults/main.yml
View file @
917f9ca5
...
...
@@ -34,4 +34,6 @@ security_debian_pkgs:
-
unattended-upgrades
-
gcc
security_redhat_pkgs
:
[]
security_redhat_pkgs
:
-
yum-plugin-security
-
yum-cron
playbooks/roles/security/tasks/main.yml
View file @
917f9ca5
...
...
@@ -23,3 +23,7 @@
-
include
:
security-ubuntu.yml
when
:
ansible_distribution == 'Ubuntu'
-
include
:
security-amazon.yml
when
:
ansible_distribution == 'Amazon'
playbooks/roles/security/tasks/security-amazon.yml
0 → 100644
View file @
917f9ca5
---
#### Enable periodic security updates
-
name
:
Install security packages
yum
:
name
:
"
{{
item
}}"
state
:
latest
update_cache
:
yes
with_items
:
"
{{
security_redhat_pkgs
}}"
-
name
:
Enable automatic start for update service
service
:
name
:
yum-cron
enabled
:
yes
state
:
started
-
name
:
Update all system packages
yum
:
name
:
'
*'
state
:
latest
when
:
SAFE_UPGRADE_ON_ANSIBLE
-
name
:
Configure security auto-updates
lineinfile
:
dest
:
/etc/yum/yum-cron.conf
regexp
:
"
{{
item.regexp
}}"
line
:
"
{{
item.line
}}"
with_items
:
-
{
regexp
:
'
^update_cmd'
,
line
:
'
update_cmd
=
security'
}
-
{
regexp
:
'
^apply_updates'
,
line
:
'
apply_updates
=
yes'
}
-
name
:
"
Take
security
updates
during
ansible
runs"
command
:
"
{{
item
}}"
when
:
SECURITY_UPGRADE_ON_ANSIBLE
with_items
:
-
yum check-update --security
-
yum update --security -y
playbooks/roles/splunk-server/meta/main.yml
View file @
917f9ca5
...
...
@@ -12,5 +12,7 @@
dependencies
:
-
role
:
user
user_info
:
"
{{
COMMON_USER_INFO
}}"
-
role
:
security
when
:
COMMON_SECURITY_UPDATES
-
role
:
mount_ebs
volumes
:
"
{{
SPLUNK_VOLUMES
}}"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment