terraform-provider-edge-con.../examples/authentication/env-vars-userpass.sh

24 lines
819 B
Bash
Executable file

#!/bin/bash
# Example: Using environment variables for username/password authentication
#
# This script demonstrates how to set environment variables for
# username/password authentication with the Edge Connect provider.
# Set the API endpoint
export EDGE_CONNECT_ENDPOINT="https://api.edge-connect.example.com"
# Set username and password
export EDGE_CONNECT_USERNAME="your-username"
export EDGE_CONNECT_PASSWORD="your-password"
# Now you can run Terraform commands without passing credentials
echo "Environment variables set. You can now run:"
echo " terraform init"
echo " terraform plan"
echo " terraform apply"
# Example: Run terraform plan
# terraform plan
# Note: You can also set these in your shell profile (~/.bashrc, ~/.zshrc)
# or use a tool like direnv for directory-specific environment variables