Reduce the startup time of the software on AWS from one minute to five seconds. (#221)
* feat: use SSD with high throughput * fix&refactor: update AMI ID and change EBS volume type to gp3 with adjusted IOPS and throughput
This commit is contained in:
@@ -35,7 +35,7 @@ DEFAULT_REGION = "us-east-1"
|
|||||||
# todo: Add doc for the configuration of image, security group and network interface
|
# todo: Add doc for the configuration of image, security group and network interface
|
||||||
# todo: public the AMI images
|
# todo: public the AMI images
|
||||||
IMAGE_ID_MAP = {
|
IMAGE_ID_MAP = {
|
||||||
"us-east-1": "ami-03a22c6e501415fb1",
|
"us-east-1": "ami-025b3f907e5c1b805",
|
||||||
"ap-east-1": "ami-0c092a5b8be4116f5",
|
"ap-east-1": "ami-0c092a5b8be4116f5",
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -102,8 +102,11 @@ def _allocate_vm(region=DEFAULT_REGION):
|
|||||||
{
|
{
|
||||||
"DeviceName": "/dev/sda1",
|
"DeviceName": "/dev/sda1",
|
||||||
"Ebs": {
|
"Ebs": {
|
||||||
'VolumeType': 'io2',
|
# "VolumeInitializationRate": 300
|
||||||
'Iops': 16000,
|
"VolumeSize": 30, # Size in GB
|
||||||
|
"VolumeType": "gp3", # General Purpose SSD
|
||||||
|
"Throughput": 1000,
|
||||||
|
"Iops": 4000 # Adjust IOPS as needed
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -133,8 +133,11 @@ class AWSProvider(Provider):
|
|||||||
{
|
{
|
||||||
"DeviceName": "/dev/sda1",
|
"DeviceName": "/dev/sda1",
|
||||||
"Ebs": {
|
"Ebs": {
|
||||||
'VolumeType': 'io2',
|
# "VolumeInitializationRate": 300
|
||||||
'Iops': 16000,
|
"VolumeSize": 30, # Size in GB
|
||||||
|
"VolumeType": "gp3", # General Purpose SSD
|
||||||
|
"Throughput": 1000,
|
||||||
|
"Iops": 4000 # Adjust IOPS as needed
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Reference in New Issue
Block a user