#!/bin/bash

cd "$(dirname "$0")"

#echo "SMARTKIT_PRINTING_SERVICE_DIR" $1
#echo "PRN_SVC_NAME" $2

export TF_VAR_base_dir="${1}/${2}"
export TF_VAR_container_name="$2"

#echo "TF_VAR_base_dir" $TF_VAR_base_dir
#echo "TF_VAR_container_name" $TF_VAR_container_name

export TF_VAR_container_port=99999

echo Stopping service and destroy infrastructure
sudo -E terraform destroy -auto-approve -var docker_host=unix:///var/run/docker.sock
