Skip to content

Commit

Permalink
reverts order of running the images
Browse files Browse the repository at this point in the history
  • Loading branch information
SonOfLope committed Nov 19, 2023
1 parent 3c4f3a6 commit 2f5c818
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
4 changes: 2 additions & 2 deletions grav/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ version: '3.8'

services:
grav-init:
depends_on:
- grav
build:
context: ./init-grav
dockerfile: Dockerfile
Expand All @@ -12,6 +10,8 @@ services:
- grav_data:/var/www/html

grav:
depends_on:
- grav-init
build: .
container_name: grav_cms
ports:
Expand Down
13 changes: 1 addition & 12 deletions grav/init-grav/copy-theme.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,7 @@

THEMES_DIR=/var/www/html/user/themes

# Function to check if Grav is ready
is_grav_ready() {
[ -d /var/www/html ]
}

# Wait for Grav to be ready
while ! is_grav_ready; do
echo "Waiting for Grav to be ready..."
sleep 10
done

echo "Grav is ready. Copying theme..."
echo " Copying theme..."

# Create the themes directory if it does not exist
[ ! -d "$THEMES_DIR" ] && mkdir -p "$THEMES_DIR"
Expand Down

0 comments on commit 2f5c818

Please sign in to comment.