mirror of https://github.com/citusdata/citus.git
find core files from correct path on CI (#6535)
Finds core files from correct path on CI. According to default core pattern on CI, core is generated at the location relative to binary is executed. It can be safe to set core pattern before running binary but to change a kernel param(in our case kernel.core_pattern), you need related privilege in docker container. Or you have to change it at image build. But, by default, on CI machines, kernel pattern contains a relative path to binary + pid + process name, so we do not need to set it explicitly for now. (Example core file name on CI machine: `core.2559.!usr!lib!postgresql!14!bin!postgres`)pull/6473/head
parent
ad6450b793
commit
6781ace3a1
|
@ -167,8 +167,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- run:
|
||||
|
@ -258,8 +259,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- store_artifacts:
|
||||
|
@ -339,8 +341,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- store_artifacts:
|
||||
|
@ -405,8 +408,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- store_artifacts:
|
||||
|
@ -483,8 +487,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- store_artifacts:
|
||||
|
@ -600,8 +605,9 @@ jobs:
|
|||
name: 'Copy coredumps'
|
||||
command: |
|
||||
mkdir -p /tmp/core_dumps
|
||||
if ls core.* 1> /dev/null 2>&1; then
|
||||
cp core.* /tmp/core_dumps
|
||||
core_files=( $(find . -type f -regex .*core.*\d*.*postgres) )
|
||||
if [ ${#core_files[@]} -gt 0 ]; then
|
||||
cp "${core_files[@]}" /tmp/core_dumps
|
||||
fi
|
||||
when: on_fail
|
||||
- store_artifacts:
|
||||
|
|
Loading…
Reference in New Issue