Why don't the instances in the auto-scaling group get assigned public ip addresses unless it's a default vpc?
i got the answer from aws support:

he reason why you are seeing that notification is because it is in accordance to your launch configuration (staging-1-deploy) settings. During the creation of a launch configuration, the assignment of public IP addresses to EC2 instances defaults to Only assign a public IP address to instances launched in the default VPC and subnet. (default) [1]. To support automatic assignment of public IP addresses to your EC2 instances as they are launched, you will have to change the launch configuration settings. Since a launch configuration cannot be edited [2], you can create a new one by copying your current launch configuration. Follow the steps below to achieve this:

1 - Go to your AWS console, select Launch Configurations, select staging-1-codedeploy 
2 - At the bottom of the details, click the grey Copy Configuration button on the right. 
3 -  ClickEdit Details link, then click Advanced Details on the resulting page.
4 -  Go to IP Address Type and select the second option, Assign a public IP address to every instance.
5 - [optional] Change the name of the launch configuration if need be and 
6 - Save launch configuration

You can now proceed to use your new launch configuration for your auto-scaling group and all your EC2 instances will be assigned public IP addresses as desired. 
I have attached a few screenshots to show some of the steps described above.