Skip to content

Commit

Permalink
Set core file in DockerStatic role
Browse files Browse the repository at this point in the history
Signed-off-by: Stewart X Addison <sxa@redhat.com>
  • Loading branch information
sxa committed Feb 12, 2021
1 parent aed49ac commit 9528afc
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
roles:
- Debug
- Version
- adopt_etc
- Providers # AdoptOpenJDK Infrastructure
- Get_Vendor_Files
- Jenkins_User # AdoptOpenJDK Infrastructure
- Superuser # AdoptOpenJDK Infrastructure
- adopt_etc
- role: Swap_File
- role: Crontab
- role: NTP_TIME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,17 @@
command: docker run -p 2227:22 --cpus=2.0 --memory=6G --detach --name f33.2227 aqa_f33
tags: startcontainers
ignore_errors: yes

# lineinfile does not work here - similar to the operation in /var/log in adopt_etc
# lineinfile: path /proc/sys/kernel/core_pattern state: present: regexp: . line: core.%p
# therefore the following section wil not become live prior to a reboot
#
- name: Make core file setting live immediately;
command: "echo core.%p > /proc/sys/kernel/core_pattern"

- name: Ensure core files are able to be created within docker containers on reboot
lineinfile:
path: /etc/sysctl.conf
state: present
regexp: kernel_core_pattern
line: kernel.core_pattern = core.%p

0 comments on commit 9528afc

Please sign in to comment.