Eb platform create fails with Ruby SDK deprecated error

I am using the latest platform to build a custom platform but it fails with that message. The exact log is:

[CMD-PackerBuild/PackerBuild/PackerBuildHook/build.rb] : Activity execution failed, because: Version 2 of the Ruby SDK will enter maintenance mode as of November 20, 2020. To continue receiving service updates and new features, please upgrade to Version 3. More information can be found here: https://aws.amazon.com/blogs/developer/deprecation-schedule-for-aws-sdk-for-ruby-v2/
  'packer build' failed, the build log has been saved to '/var/log/packer-builder/answerhub:1.0.30-builder.log' (ElasticBeanstalk::ExternalInvocationError)

I tried terminating the old eb instance but it did not fix it. I tried to ssh into the instance and update Ruby, but I am unable to do so, since the ssh port is not open.
Any feedback will be greatly appreciated.