Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a way to increase volume size of instance created #212

Open
Nitish1814 opened this issue Jan 26, 2025 · 7 comments
Open

Is there a way to increase volume size of instance created #212

Nitish1814 opened this issue Jan 26, 2025 · 7 comments

Comments

@Nitish1814
Copy link

Nitish1814 commented Jan 26, 2025

Hi,
I have created an AMI with 256 GB snapshot. However when I spinning up EC2 in workflow, it is creating instance with 8GB volume only. Do I need to specify some additional input in 'with' ?
PS: Creating instance manually from AWS console using given AMI creates instance with 256GB

        uses: machulav/ec2-github-runner@v2
        with:
          mode: start
          github-token: ${{ inputs.PAT }}
          ec2-image-id: ami-xyz
          ec2-instance-type: t3.xlarge
          subnet-id: subnet-xyz
          security-group-id: sg-xyz

Regards,

@Preen
Copy link
Collaborator

Preen commented Jan 26, 2025

Hmm, this seems off. Are you 100% sure that you are using the correct ami within the same region?

@Nitish1814
Copy link
Author

Hmm, this seems off. Are you 100% sure that you are using the correct ami within the same region?

Hi,
AMI is correct with 250GB snapshot. I am suspecting internally when RunInstancesCommand is fired then do it take default block device mapping ?

@Nitish1814
Copy link
Author

Hi Team,
Can we add block device mapping volume size also as a part of input while running runInstancesCommand ?

  "BlockDeviceMappings": [
    {
      "DeviceName": "/dev/sdh",
      "Ebs": {
        "**VolumeSize**": 100
      }
    }
  ],
  "ImageId": "ami-abc12345",
  "InstanceType": "t2.micro",
  "SubnetId": "subnet-6e7f829e"

@Preen
Copy link
Collaborator

Preen commented Jan 27, 2025

I dont have the time to implement this but do have the time to test it if you push a pull request? :)

I have not been able to recreate your issue with the wrong disk size on the nodes that Im starting.

@Nitish1814
Copy link
Author

I dont have the time to implement this but do have the time to test it if you push a pull request? :)

I have not been able to recreate your issue with the wrong disk size on the nodes that Im starting.

sure, I'll then raise PR for this change in sometime as soon as I get some bandwidth.

Thanks,

@stecullum
Copy link

Just to confirm when i use my custom AMI it always uses the AMI instance disk size..

@Nitish1814
Copy link
Author

Nitish1814 commented Feb 3, 2025

Just to confirm when i use my custom AMI it always uses the AMI instance disk size..

Hi @stecullum @Preen, the EBS snapshot associated with your AMI (say 256 GB). does it spin up an EC2 instance with 256 GB volume also?

You can look at AMI description and EBS Snapshot attached with 256GB but then also when instance is created only 8GB is assigned to it

Image

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants