Welcome to mirror list, hosted at ThFree Co, Russian Federation.

run-parts.sh « miniraspbian « docker - github.com/nextcloud/nextcloudpi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: b4e9f74ab44939904d026c305b5560641e03b731 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash

cleanup()
{
  for file in $( ls -1rv /etc/cont-init.d ); do
    /etc/cont-init.d/$file stop
  done
  exit
}

trap cleanup SIGTERM

for file in $( ls -1v /etc/cont-init.d ); do
  /etc/cont-init.d/$file start
done

echo "Init done"
while true; do sleep 0.5; done # do nothing, just wait for trap from 'docker stop'