I have the following standalone docker-compose.yml file:
version: "3"
services:
feed_activator:
container_name: feed_activator
image: docker
volumes: [ "/var/run/docker.sock:/var/run/docker.sock" ]
command: [ "/bin/sh", "-c", "apk --no-cache add curl", "while true; do sleep 60; curl 'https://google.com'; done" ]
restart: "always"
what I would expect it to do is to simply install curl and send a GET request to https://google.com every minute.
What happens instead is
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/community/x86_64/APKINDEX.tar.gz
(1/4) Installing brotli-libs (1.0.9-r3)
(2/4) Installing nghttp2-libs (1.42.0-r1)
(3/4) Installing libcurl (7.78.0-r0)
(4/4) Installing curl (7.78.0-r0)
Executing busybox-1.32.1-r6.trigger
OK: 13 MiB in 24 packages
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/community/x86_64/APKINDEX.tar.gz
OK: 13 MiB in 24 packages
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/community/x86_64/APKINDEX.tar.gz
OK: 13 MiB in 24 packages
where the
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/community/x86_64/APKINDEX.tar.gz
OK: 13 MiB in 24 packages
part is repeating endlessly and the container is in a restarting state. What do I have to do for it to function correctly? Any hint would be much appreciated.