I am trying to deploy an application revision to an existing aws instance using eb deploy, and I've spent several days browsing Amazon's documentation as well as well as related web articles including stack overflow questions and answers, to no avail. The problem is that I can't figure out how to specify the cname to which the application should be deployed. I'm a newbie so any help will be gratefully appreciated.
Your elastic beanstalk environment, where you deployed your revision has a url assigned to it. You can check it in AWS console, or querying your environment in AWS CLI. If you have one instance only, this url will point to your instance. If you have more than one instance in your environment the url will point to your environment elastic load balancer. It does'n matter. In each case, the url will be the same.
Create an CNAME record to point to elastic beanstalk environment url. It will work fine. Even better, if you use the AWS route53 service you can create an Alias record that has some advantages if all your services are across AWS environment.
Related
The current setup was the application is load-balanced at AWS. The domain(www.Example.com) we are using is registered at GoDaddy.com.
My concern is that, do we need to upgrade our GoDaddy hosting even if the files are load-balance at AWS?
Let's say that we have had a 50K concurrent users.
Thanks for the insight in-advanced.
When you say "the application is load-balanced at AWS", it suggests that there is the following setup on AWS:
One or more Amazon EC2 instances running a web application, and
An Elastic Load Balancer that is directing incoming traffic to those instances
Your GoDaddy account probably has a Domain Name with a CNAME record that points to the DNS Name of the Load Balancer on AWS.
If this is true, then you do not need a "hosting plan" on GoDaddy, since it would just be managing your Domain Name. Scaling is not necessary for Domain Names.
Increasing the load would possibly require creating additional EC2 instances on AWS, but you might have an Auto Scaling group doing this for you automatically.
You should investigate what you actually have on GoDaddy and on AWS.
I have an Elastic Beanstalk instance that is running a Flask app. I want to know if there is any way through AWS to automatically block IP addresses that are doing unusual activity on my site.
This could be a range of things, for example:
Send several GET requests over and over
Trying to POST without a CSRF
And more. Any ideas? Thanks.
Generally, for that you would front your EB with application load balancer and AWS Web Application Firewall.
This setup is documented in the recent AWS blog and other sources:
How do I protect my Elastic Beanstalk environment against attacks from known unwanted hosts?
Setting up AWS Web Application Firewall (WAF) with Elastic Beanstalk
Guidelines for Implementing AWS WAF
I have developed a website with Jsp and Servlets. I want to make it live on a domain that I have purchased already. How can I do that. I would like to prefer Aws. Please guide me with the process.
Have a look at Elastic Beanstalk as it supports Tomcat.
If you did not buy your domain through AWS/Route 53 you also need to point your domain to the nameservers of Route 53
Within AWS you generally use Route 53 to configure domain names, have a look at pointing it at your Elastic Beanstalk application
There are other alternatives for hosting your application on AWS but I believe Elastic Beanstalk is good if you are new to AWS. You could package your application into a Docker container and run it on Elastic Beanstalk that way or on ECS (Elastic Container Service).
I have aspnet webdeploy package(.zip) now i want it to deploy in AWS with cloudformation.
my cloudformation should contain
vpc with two subnet (private and public)
Private subnet will contain Instance and RDS(sqlserver web or any)
Public Subnet will have NAT, Bastian host (for login into actual instance) and internet gateway.
Cloudformation should pick appication(zip) from s3 URL.
and at the end as output i can get URL (working website).
anyhelp would be really appreciated (if someone has cloudformation which do the same please post it here or send me on kotnala.ajayk#gmail.com)
Thanks,
Ajay
Unless you have requirements to use CloudFormation directly, I would recommend using AWS Elastic Beanstalk and the AWS Console to setup your VPC and deploy your application. Using the AWS Console to create a VPC with public and private subnets is much easier than creating them via CloudFormation, and Elastic Beanstalk supports ASP.NET application deployment automatically. EB uses a CloudFormation template to manage its own resources and can be customized later if needed.
Read through the Launching an Elastic Beanstalk Application in a VPC with Bastion Hosts, Launching an Elastic Beanstalk in a VPC with Amazon RDS and How to Deploy a .NET Sample Application Using AWS Elastic Beanstalk examples, which should get you started. Your requirements are all covered by some combination of the steps listed in those three examples.
Once you've become familiar with how to use Elastic Beanstalk to configure and deploy your application package, you can also look into managing your Elastic Beanstalk environment from a CloudFormation template, to automate the full process. See Elastic Beanstalk Template Snippets for getting started with this step.
Our app has independent clusters of boxes running on Amazon Web Services. I need to send http requests to different clusters based on the URL. For example, http://api.mydomain.com/foo should go to the "foo" cluster, and http://api.mydomain.com/bar should go to the "bar" cluster.
I don't see anything in the elastic load balancer or Route 53 that will do it.
(The obvious thing is to have separate subdomains, but that's difficult for this app. We want to stick with just the "api" subdomain because the cluster configuration may change in the future.)
What's the best approach?
That is not supported by the load balancer. Using subdomains does work if you want to use the existing load balancer.
If you need more features, you could configure your own using a software load balancer running on top of an ec2 instance. Not likely to be as cost effective however.
It is not possible using ELB. Use Netscaler EC2 or HAProxy EC2 in your AWS environment to achieve this. NetScaler is available in AWS marketplace.