weaveworks / wks-quickstart-firekube

Example configuration to create Kubernetes clusters powered by ignite and gitops
342 stars 370 forks source link

cd to SCRIPT_DIR before setup or cleanup #61

Closed stealthybox closed 5 years ago

stealthybox commented 5 years ago

Both of these scripts either create or operate on ./footloose.yaml which is intended to be created in the same directory as setup.js and config.yaml.

Use bash features to ensure file operations occur from the same directory regardless of how the script is executed.

stealthybox commented 5 years ago

The only bug I think needs to be solved for this is to detect if --git-deploy-key is a relative path. If so, it should be prepended with "${SCRIPT_DIR}".

It doesn't affect absolute paths.

stealthybox commented 5 years ago

Fixed -- thanks!