Skip to content

Commit

Permalink
update generate to be safe to call from anywhere
Browse files Browse the repository at this point in the history
  • Loading branch information
jonfriesen committed May 24, 2024
1 parent 6911df0 commit 8e05b1e
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 8 deletions.
12 changes: 9 additions & 3 deletions apps/.tools/generate.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
#!/bin/bash

# Get the directory of the current script
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")

# Move to one directory above the script directory
cd "$SCRIPT_DIR/.."

# Read the templates from files
DOCKER_COMPOSE_HEADER=$(cat .tools/compose-header.yml)
QTAP_LOCAL_SERVICE=$(cat .tools/qtap-service.yml)
SERVICE_TEMPLATE=$(cat .tools/service-template.yml)
DOCKER_COMPOSE_HEADER=$(cat "$SCRIPT_DIR/compose-header.yml")
QTAP_LOCAL_SERVICE=$(cat "$SCRIPT_DIR/qtap-service.yml")
SERVICE_TEMPLATE=$(cat "$SCRIPT_DIR/service-template.yml")

# Initialize the services array and port
services=()
Expand Down
2 changes: 1 addition & 1 deletion apps/curl-geoweather/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
depends_on:
- qtap.local
qtap.local:
image: "qpoint:dev"
image: "us-docker.pkg.dev/qpoint-edge/public/qpoint:head"
environment:
- TOKEN=${TOKEN}
command: >
Expand Down
2 changes: 1 addition & 1 deletion apps/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ services:
depends_on:
- qtap.local
qtap.local:
image: "qpoint:dev"
image: "us-docker.pkg.dev/qpoint-edge/public/qpoint:head"
environment:
- TOKEN=${TOKEN}
command: >
Expand Down
2 changes: 1 addition & 1 deletion apps/go-geoweather/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
depends_on:
- qtap.local
qtap.local:
image: "qpoint:dev"
image: "us-docker.pkg.dev/qpoint-edge/public/qpoint:head"
environment:
- TOKEN=${TOKEN}
command: >
Expand Down
2 changes: 1 addition & 1 deletion apps/php-geoweather/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
depends_on:
- qtap.local
qtap.local:
image: "qpoint:dev"
image: "us-docker.pkg.dev/qpoint-edge/public/qpoint:head"
environment:
- TOKEN=${TOKEN}
command: >
Expand Down
2 changes: 1 addition & 1 deletion apps/python-geoweather/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
depends_on:
- qtap.local
qtap.local:
image: "qpoint:dev"
image: "us-docker.pkg.dev/qpoint-edge/public/qpoint:head"
environment:
- TOKEN=${TOKEN}
command: >
Expand Down

0 comments on commit 8e05b1e

Please sign in to comment.