Skip to content

Commit

Permalink
add shared pid namespace test of start.sh kill pause 1
Browse files Browse the repository at this point in the history
  • Loading branch information
wenxinlee2015 committed Mar 11, 2021
1 parent 9a94dea commit 11a670f
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
3 changes: 3 additions & 0 deletions core/centos-shellscript-kill-pause-dockerfile/dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
FROM centos
ADD ./start.sh /root/start.sh
ENTRYPOINT [ "/root/start.sh" ]
9 changes: 9 additions & 0 deletions core/centos-shellscript-kill-pause-dockerfile/start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash
sleep 20
kill 1
while :
do
sleep 20
date
echo "sleep 20s"
done
9 changes: 2 additions & 7 deletions core/pod-sharepid.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,5 @@ spec:
- name: nginx
image: nginx
- name: shell
image: centos
securityContext:
capabilities:
add:
- SYS_PTRACE
stdin: true
tty: true
image: centos:v1
imagePullPolicy: IfNotPresent

0 comments on commit 11a670f

Please sign in to comment.