diff --git a/spotty/__init__.py b/spotty/__init__.py index 72837bd..e398332 100644 --- a/spotty/__init__.py +++ b/spotty/__init__.py @@ -1 +1 @@ -__version__ = '1.3.1' +__version__ = '1.3.2' diff --git a/spotty/providers/aws/cfn_templates/instance/data/startup_scripts/02_mount_volumes.sh b/spotty/providers/aws/cfn_templates/instance/data/startup_scripts/02_mount_volumes.sh index f5b4821..4801c4d 100644 --- a/spotty/providers/aws/cfn_templates/instance/data/startup_scripts/02_mount_volumes.sh +++ b/spotty/providers/aws/cfn_templates/instance/data/startup_scripts/02_mount_volumes.sh @@ -13,7 +13,7 @@ do # NVMe EBS volume (see: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nvme-ebs-volumes.html) if [ ! -b $DEVICE ]; then - VOLUME_ID=$(cfn-get-metadata --stack ${AWS::StackName} --region us-east-2 --resource VolumeAttachment${!DEVICE_LETTERS[$i]^} -k VolumeId) + VOLUME_ID=$(cfn-get-metadata --stack ${AWS::StackName} --region ${AWS::Region} --resource VolumeAttachment${!DEVICE_LETTERS[$i]^} -k VolumeId) DEVICE=$(lsblk -o NAME,SERIAL -dpJ | jq -rc ".blockdevices[] | select(.serial == \"${!VOLUME_ID//-}\") | .name") if [ -z "$DEVICE" ]; then echo "Device for the volume $VOLUME_ID not found"