mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-23 15:40:07 -06:00
ebcf7455eb
* Rename module name from "github.com/hashicorp/terraform" to "github.com/placeholderplaceholderplaceholder/opentf". Signed-off-by: Jakub Martin <kubam@spacelift.io> * Gofmt. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Regenerate protobuf. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Fix comments. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Undo issue and pull request link changes. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Undo comment changes. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Fix comment. Signed-off-by: Jakub Martin <kubam@spacelift.io> * Undo some link changes. Signed-off-by: Jakub Martin <kubam@spacelift.io> * make generate && make protobuf Signed-off-by: Jakub Martin <kubam@spacelift.io> --------- Signed-off-by: Jakub Martin <kubam@spacelift.io>
27 lines
1.2 KiB
Bash
Executable File
27 lines
1.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# This is a helper script to launch Terraform inside the "dlv" debugger,
|
|
# configured to await a remote debugging connection on port 2345. You can
|
|
# then connect to it using the following command, or its equivalent in your
|
|
# debugging frontend of choice:
|
|
# dlv connect 127.0.0.1:2345
|
|
#
|
|
# This tool does not install dlv. To install it, see its instructions:
|
|
# https://github.com/derekparker/delve/tree/master/Documentation/installation
|
|
#
|
|
# For more convenient use, you may wish to put this script in your PATH:
|
|
# ln -s ../src/github.com/placeholderplaceholderplaceholder/opentf/scripts/debug-terraform $GOPATH/bin/debug-terraform
|
|
#
|
|
# Note that when running this script the Terraform binary is NOT in $GOPATH/bin,
|
|
# so any providers installed there won't be found unless Terraform searches
|
|
# there for some _other_ reason.
|
|
|
|
set -eu
|
|
|
|
echo "Launching Terraform in a headless debug session"
|
|
echo "Connect to it using: dlv connect 127.0.0.1:2345"
|
|
echo "(Terraform takes a long time to build and launch in this mode; some logs will appear below)"
|
|
echo "---------------------------"
|
|
|
|
exec dlv debug github.com/hashicorp/terraform --headless --listen :2345 --log -- "$@"
|