File tree Expand file tree Collapse file tree 24 files changed +216
-84
lines changed
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
provision/roles/webdevops-base/tasks/bootstrap
samson-deployment/latest/conf
provision/roles/webdevops-base/tasks/bootstrap
provisioning/base/general
provision/roles/webdevops-base/tasks/bootstrap Expand file tree Collapse file tree 24 files changed +216
-84
lines changed Original file line number Diff line number Diff line change @@ -60,10 +60,12 @@ function replaceTextInFile() {
6060 #
6161 # #
6262function includeScriptDir() {
63- for FILE in " $1 " /* .sh; do
64- # run custom scripts, only once
65- . " $FILE "
66- done
63+ if [[ -d " $1 " ]]; then
64+ for FILE in " $1 " /* .sh; do
65+ # run custom scripts, only once
66+ . " $FILE "
67+ done
68+ fi
6769}
6870
6971# ##
@@ -144,6 +146,7 @@ function runProvisionOnBuild() {
144146 # #
145147function runProvisionEntrypoint() {
146148 includeScriptDir " /opt/docker/provision/entrypoint.d"
149+ includeScriptDir " /entrypoint.d"
147150
148151 runDockerProvision entrypoint
149152}
Original file line number Diff line number Diff line change 11---
22
3- - name : Register logrotate configurations
3+ - name : Create /entrypoint.d
44 file :
5- src : ' /opt/docker/provision/entrypoint.d'
6- dest : ' /entrypoint.d'
5+ path : " /entrypoint.d"
6+ state : directory
7+ owner : " root"
8+ group : " root"
9+ mode : 0700
10+
11+ - name : Create /entrypoint.cmd
12+ file :
13+ src : ' /opt/docker/bin/entrypoint.d'
14+ dest : ' /entrypoint.cmd'
715 state : link
816 force : yes
Original file line number Diff line number Diff line change @@ -60,10 +60,12 @@ function replaceTextInFile() {
6060 #
6161 # #
6262function includeScriptDir() {
63- for FILE in " $1 " /* .sh; do
64- # run custom scripts, only once
65- . " $FILE "
66- done
63+ if [[ -d " $1 " ]]; then
64+ for FILE in " $1 " /* .sh; do
65+ # run custom scripts, only once
66+ . " $FILE "
67+ done
68+ fi
6769}
6870
6971# ##
@@ -144,6 +146,7 @@ function runProvisionOnBuild() {
144146 # #
145147function runProvisionEntrypoint() {
146148 includeScriptDir " /opt/docker/provision/entrypoint.d"
149+ includeScriptDir " /entrypoint.d"
147150
148151 runDockerProvision entrypoint
149152}
Original file line number Diff line number Diff line change 11---
22
3- - name : Register logrotate configurations
3+ - name : Create /entrypoint.d
44 file :
5- src : ' /opt/docker/provision/entrypoint.d'
6- dest : ' /entrypoint.d'
5+ path : " /entrypoint.d"
6+ state : directory
7+ owner : " root"
8+ group : " root"
9+ mode : 0700
10+
11+ - name : Create /entrypoint.cmd
12+ file :
13+ src : ' /opt/docker/bin/entrypoint.d'
14+ dest : ' /entrypoint.cmd'
715 state : link
816 force : yes
Original file line number Diff line number Diff line change @@ -60,10 +60,12 @@ function replaceTextInFile() {
6060 #
6161 # #
6262function includeScriptDir() {
63- for FILE in " $1 " /* .sh; do
64- # run custom scripts, only once
65- . " $FILE "
66- done
63+ if [[ -d " $1 " ]]; then
64+ for FILE in " $1 " /* .sh; do
65+ # run custom scripts, only once
66+ . " $FILE "
67+ done
68+ fi
6769}
6870
6971# ##
@@ -144,6 +146,7 @@ function runProvisionOnBuild() {
144146 # #
145147function runProvisionEntrypoint() {
146148 includeScriptDir " /opt/docker/provision/entrypoint.d"
149+ includeScriptDir " /entrypoint.d"
147150
148151 runDockerProvision entrypoint
149152}
Original file line number Diff line number Diff line change 11---
22
3- - name : Register logrotate configurations
3+ - name : Create /entrypoint.d
44 file :
5- src : ' /opt/docker/provision/entrypoint.d'
6- dest : ' /entrypoint.d'
5+ path : " /entrypoint.d"
6+ state : directory
7+ owner : " root"
8+ group : " root"
9+ mode : 0700
10+
11+ - name : Create /entrypoint.cmd
12+ file :
13+ src : ' /opt/docker/bin/entrypoint.d'
14+ dest : ' /entrypoint.cmd'
715 state : link
816 force : yes
Original file line number Diff line number Diff line change @@ -60,10 +60,12 @@ function replaceTextInFile() {
6060 #
6161 # #
6262function includeScriptDir() {
63- for FILE in " $1 " /* .sh; do
64- # run custom scripts, only once
65- . " $FILE "
66- done
63+ if [[ -d " $1 " ]]; then
64+ for FILE in " $1 " /* .sh; do
65+ # run custom scripts, only once
66+ . " $FILE "
67+ done
68+ fi
6769}
6870
6971# ##
@@ -144,6 +146,7 @@ function runProvisionOnBuild() {
144146 # #
145147function runProvisionEntrypoint() {
146148 includeScriptDir " /opt/docker/provision/entrypoint.d"
149+ includeScriptDir " /entrypoint.d"
147150
148151 runDockerProvision entrypoint
149152}
Original file line number Diff line number Diff line change 11---
22
3- - name : Register logrotate configurations
3+ - name : Create /entrypoint.d
44 file :
5- src : ' /opt/docker/provision/entrypoint.d'
6- dest : ' /entrypoint.d'
5+ path : " /entrypoint.d"
6+ state : directory
7+ owner : " root"
8+ group : " root"
9+ mode : 0700
10+
11+ - name : Create /entrypoint.cmd
12+ file :
13+ src : ' /opt/docker/bin/entrypoint.d'
14+ dest : ' /entrypoint.cmd'
715 state : link
816 force : yes
Original file line number Diff line number Diff line change @@ -60,10 +60,12 @@ function replaceTextInFile() {
6060 #
6161 # #
6262function includeScriptDir() {
63- for FILE in " $1 " /* .sh; do
64- # run custom scripts, only once
65- . " $FILE "
66- done
63+ if [[ -d " $1 " ]]; then
64+ for FILE in " $1 " /* .sh; do
65+ # run custom scripts, only once
66+ . " $FILE "
67+ done
68+ fi
6769}
6870
6971# ##
@@ -144,6 +146,7 @@ function runProvisionOnBuild() {
144146 # #
145147function runProvisionEntrypoint() {
146148 includeScriptDir " /opt/docker/provision/entrypoint.d"
149+ includeScriptDir " /entrypoint.d"
147150
148151 runDockerProvision entrypoint
149152}
Original file line number Diff line number Diff line change 11---
22
3- - name : Register logrotate configurations
3+ - name : Create /entrypoint.d
44 file :
5- src : ' /opt/docker/provision/entrypoint.d'
6- dest : ' /entrypoint.d'
5+ path : " /entrypoint.d"
6+ state : directory
7+ owner : " root"
8+ group : " root"
9+ mode : 0700
10+
11+ - name : Create /entrypoint.cmd
12+ file :
13+ src : ' /opt/docker/bin/entrypoint.d'
14+ dest : ' /entrypoint.cmd'
715 state : link
816 force : yes
You can’t perform that action at this time.
0 commit comments