added curl with loop
This commit is contained in:
13
curl/Dockerfile
Normal file
13
curl/Dockerfile
Normal file
@@ -0,0 +1,13 @@
|
||||
FROM centos:7
|
||||
RUN yum update -y
|
||||
RUN yum install curl -y
|
||||
RUN yum clean all
|
||||
COPY docker-entrypoint.sh /
|
||||
RUN chmod +x /docker-entrypoint.sh
|
||||
ENTRYPOINT ["/docker-entrypoint.sh"]
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
15
curl/docker-entrypoint.sh
Normal file
15
curl/docker-entrypoint.sh
Normal file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ ! -z "${LOOP}"]]; then
|
||||
while :
|
||||
do
|
||||
curl "$@"
|
||||
sleep "${LOOP}"
|
||||
done
|
||||
else
|
||||
curl "$@"
|
||||
fi
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user