Trouble deploying to AWS Elastic Beanstalk

I have a fresh AWS account. First-time using Elastic Beanstalk so my apologies if I'm overlooking something very simple

I get this error when deploying to AWS Elastic Beanstalk: Cannot read property 'vpc-3db96745' of undefined

I did the following:

  1. Clicked on the "Launch on AWS" link from https://www.metabase.com/start/aws.html

  2. Entered and verified availability of a unique domain under Environment Information

  3. Checked "Upload your code" under Base Configuration

  4. Clicked "Review and launch"

The screen then displays a loading symbol with the following messages in order of appearance:

"Describing configuration options"
"Describing configuration settings"
"Fetching RDS configuration options"

error

"Cannot read property 'vpc-3db96745' of undefined"

Any tips or pointers would be appreciated. Screenshot of error:

1 Like

I’m having the same problem, someone help! @kdoh @tom

Same issue here following the same journey. Please help!

I also got the same error message. I was able to get around this by switching to the old beanstalk UI and configuring step-by-step.

Thanks @mzukowski, I tried it but get another error below, The error is because i'm using a different region. And i want to use this region because all our other applications are in this region.

Thanks! Were you following the same guide to get the correct information.

Yes. I followed the same guide but the error is different this time as you can see in the picture above.

Thanks. I’m able to install Metabase now.
@chadhuber, I click on the URL beside my environment ID to see my Metabase at work but it display a 502 Bad Gateway error.

Hi all-

This is how I was able to resolve the issue:

  1. Go to Elastic Beanstalk: https://console.aws.amazon.com/elasticbeanstalk/home

  2. Make sure you’re in your preferred region as indicated in the upper right-hand corner

  3. Click Create New Application in the upper right-hand corner

  4. In the pop-up, name the application “Metabase”

  5. After creating the application, you will be brought to the application home screen where it says “No environments currently exist for this application. Create one now.” Click Create one now

  6. Keep Web server environment checked and click Select

This will take you to the setup screen that will look very familiar as it’s the same screenshot that everybody has been sharing. The difference is that Metabase configurations will not be pre-loaded so we must do that ourselves

  1. Under Choose platform, select Docker

  2. Under application code, select Upload your code then click the Upload button

  3. Under Source code origin, select Public S3 URL and paste in the following:

https://downloads.metabase.com.s3.amazonaws.com/v0.26.2/metabase-aws-eb.zip

Note: for those who are looking at this post in the future, please make sure this is the latest version of Metabase available

  1. Confirm the version label auto-populates, then click Upload

  2. Now click Configure more options button (which I noticed didn’t exist before), next to the blue Create environment button

  3. Under the Database section, click “Modify” and configure a Postgres with the following options:

Engine: Postgres
Engine version: 9.6.2 (the default at time of publishing)
Instance class: db.t2.micro
Storage: 10
Username: [create username]
Password: [create password]
Retenion: [up to you]
Availability: [up to you]

  1. Then click Save

  2. Now click Create environment

  3. When the environment has finished being created, go to the endpoint provided and you should have a fresh Metabase configuration rolling! The postgres database configuration (username, password, endpoint etc) will automatically be exposed to the Docker instance via environment variables

Hope this helps!

Not sure why the Metabase auto-install failed - I’ve looked at their URL and all of the options we just selected above match.

2 Likes

Thanks, @chadhuber. I have just got mine online, I did have to increase from a t2.micro, to t2.small, and enable auto-scaling. Along with downloading the zip manually, then uploading which solved the original issue.

It’s worth noting, switching to the old UI is right in the footer of the set up page.

I’m experiencing high CPU usage however, around 90%.

@billypurvis, I have a t2.micro and the CPU is currently at 1.1%

Was this after you connected a database and it was doing a lot of writes? Has the CPU usage subsided?

@chadhuber I’ve been monitoring, it seems to have gone down dramatically to 1.5% roughly - the original was before I had connected a database, perhaps it was causing an underlying issue? I was originally been given 503 errors though.

I’ve just gone down to single instance and t2.micro, to reduce costs, and hopefully be enough to support Metabase.

EDIT: Just an update: Downgrading to t2.micro and single instance worked fine, CPU usage is currently at 1.1% and I’m having no issues.

I was finally able to get this going thanks to the above steps.

Follow up question: My DB is firewalled to only allow certain IP’s.
How do I find (in aws), the IP for my elastic beanstalk config so that I can whitelist it?

I had this issue as well, if I recall I just did a ping on the elastic beanstalk url and added the IP to the whitelist. Worked for me but it was for a quick and dirty demo, not sure if it would work long term.

However, if your source DB is also hosted on AWS, you might look into putting it into the same VPC as your Elastic Beanstalk environment. That’s the AWS “right way to do it”

Thanks! That worked for me.

1 Like