How can I set an address like- 'sub-domain.elasticbeanstalk.com' in Elastic Beanstalk? - amazon-elastic-beanstalk

I have deployed my django project into AWS ELASTIC BEANSTALK (AWS EB). The default public address of the project is in this form: env-name.region-name.elasticbeanstalk.com.
After some searching I've found out I can modify the env-name portion using modifying the CNAME and I have applied it. It worked!
But, when I tried to set up a direct sub-domain like subdomain-name.elasticbeanstalk.com I couldn't do this. I have searched for a while by different search term, but I couldn't find out a way to do that.
So, my questions are-
Is it even possible to create this form of address: subdomain-name.elasticbeanstalk.com?
If it's possible, then how can I do that?
[OPTIONAL] If it's not possible, then can anyone will be able to give me an explanation?

Question 1;
This is not possible, all environments have the region in the url, this is because the dns is routed to this specific region.
Question 3;
I would suggest using your own custom domain and setup an alias/cname record to point to your beanstalk environments, explained in this documentation.

Related

gRPC Compute engine tutorial

I'm trying out GCE for grpc. In the past, I've set-up ECS (ec2 + NLB + ALB), but since I had weird behavior with the grpc server behind NLB, my team decided to try out GCE that seems to be better suited for GRPC.
I'm following the tutorial here
I need to determine the following
To determine the ENDPOINTS_SERVICE_NAME you can either:
After deploying the Endpoints configuration, go to the Endpoints page
in the Cloud Console. The list of possible ENDPOINTS_SERVICE_NAME are
shown under the Service name column.
I'm at that point since I've just finished uploading with gcloud and enabled the required services.
There is no such "service" column, the closest thing I've got is this label
Service name: bookstore.endpoints.grpc-research.cloud.goog in the "Endpoints" section
I don't know if the documentation is out of date or I am at the wrong place or I'm missing something else.
The column is Service name. It is located in the Endpoints in the UI > Endpoints / Services / Service name. And it's the same you have shared in your post.
In my case is function1.xxxxxxx.a.run.app

How to redirect particular Internet Service Providers away from my website

I'd like to redirect particular Internet Service Providers to other websites when trying to access my website (I'm a html/css newbie).
I'm not sure how to do this or whether it is possible with html/css(?), should I be looking at another language or is there a setting in Amazon Web Services that allows me to block or redirect specified ISPs.
Any ideas are very much appreciated.
I'm reminded of a story where a competitor visited a company's website to scrape pricing information. So, the company changed their website to show different prices to their competitor!
So, it seems your goal is "when requests come from IP address XX, don't give them access to my website".
Here's a few ways to achieve this:
Block traffic from a single IP using Network Access Control Lists (NACLs) — very simple and effective!
Or, you can configure rules using Advanced Request Routing for AWS Application Load Balancers
Or, you could use AWS Web Application Firewall (WAF) to block specific IP addresses
I think it would be more fun to send them to an alternative website with false information, so they don't realise you are actually blocking them!!
I reread your issue and you only wanted specific providers, this would redirect for everyone. this wont work if popups are disabled
<html>
<body onload = "forwardFunction()">
<script type="text/javascript">
function forwardFunction() {
window.open("https://www.google.com","_self");
}
</script>
If you can read this something went wrong.
</html>

App Maker: Public facing IP for UrlFetch?

What are the public facing IP addresses, when app maker calls an external service with urlfetch?
My external service insists on white-listing these. Is there a public list available from google?
Within App Maker, I want to use the UrlFetch to call an external service, very much like the App maker sample.
I see there is a list of Apps Script's IP address ranges for the JDBC. Would this be the same ranges?
(https://developers.google.com/apps-script/guides/jdbc#accessing)
Thanks in advance,
John
Since App Maker uses Apps Script's URL Fetch service, you need to look at their doc to answer this question. From what I can tell from:
https://developers.google.com/apps-script/reference/url-fetch/url-fetch-app
You need to go here:
https://cloud.google.com/appengine/kb/#static-ip
And then follow these instructions. Since Stack Overflow has an issue with simply posting links (although I really recommend you go to the link :), I'll summarize the instructions here:
nslookup -q=TXT _cloud-netblocks.googleusercontent.com 8.8.8.8
And then nslookup each "include" in the response. This gives you all the IPs currently in use.
Edit: It looks like this might be the same IPs Google uses for it's general URL fetch service, which could mean that if you're whitelisting for these IPs you may also whitelist for all App Engine applications, and probably even more. Obviously you'd be whitelisting for all Apps Script and App Maker applications, so I assume this doesn't matter, but I just wanted to mention it. If your service is trying to rely on this for security reasons then, obviously, it's not adequate.
I had the same issue,
may be you can try the "useIntranet" option which may reduce the ipaddress range within your websites/webapps current network
https://developers.google.com/apps-script/reference/url-fetch/url-fetch-app
eg:
var response = UrlFetchApp.fetch("https://Url.com",{
'method' : 'post',
'payload' :{
'useIntranet':true,
'key':"value"
}
}
);

How to restrict access to Bluemix Scalable group container to public?

I have created a scalable group container with the latest image, which is created by docker file. I have added a domain name and used an SSL certificate with it. However, I am looking to restrict this domain access to public. I would like to allow access to a specific IP range only.
Is there any approach I can use to achieve this? The client asked to allow this domain URL access within their FW network only.
Many Thanks,
Suresh
Actually there isn't any available service/configuration to restrict access to container/containers group in the IBM Containers service on Bluemix.
The only options coming to my mind could be:
filtering directly on each of your group's nodes, using iptables or the specific service configuration
have a 'filter' container (or also an application on runtime) filtering the connections according to the source IP address, for example using a proxy like varnish or ha_proxy on a container it will be pretty simple

Magento Multi-Store Setup / Store Codes Setting

I'm running Magento on a shared server with a single IP. I originally set it up as a single store with no plans to do multi-stores. Do I need to have store codes trailing each domain in magento to get this work correctly? They will all checkout at the main store URL. I have done this in the past and it has worked fine for me, but I was using store codes and with this instance I am not.
Will it completely jack up my SEO?
So I have store1.com (main store) and store2.com which needs to checkout at store1.com
Any help or link to a how to would be great. Have not been able to find a straight forward answer.
Your proposed setup of having store1.com and store2.com with a shared checkout URL of store1.com will work with a bit of work from yourself, but it's not clean or ideal in my opinion. Magento will append an SSID every time it switches domain to try and re-load the customers session data (They will have ?SSID=something). You would also need to change the checkout URL in your templates to only use the 1 domain which would require hard coding the full URL to the checkout and cart page in the store2.com templates.
Personally I would simply have separate checkouts for each domain which is supported straight out of the box in Magento without really doing anything. Why the need to have the checkout always under 1 domain? If it's because of SSL and 1 IP limitations then buy a UCC SSL certificate for multiple domains and have all the domains required to run on the server setup as SANS on the certificate. Cheap and simple. This way there is no need for store codes in URLs, SSIDs in domain switching, and the user will always stay on the same domain without any funny switching business or complications.
As a customer I would also be a little surprised to shop on one domain and then checkout on another these days, especially if one of the domains is international and this will ultimately effect your conversion rate.
You seem to be familiar with store views, so once you have setup your secondary store view, simply go into the admin and override the base URLs for the secondary domain. Point the store2.com domain to the same IP address you are using for store1.com. Setup a vhost on the server so store2.com effectively replicates the vhost for store1.com. You can use vhost directives so that magento initiates the correct store view for the relevant domain name in your new vhost.
SetEnv MAGE_RUN_CODE yourstorecode
SetEnv MAGE_RUN_TYPE store
You should now be able to have multiple sites/domains running on 1 magento instance each with an individual checkout URL. e.g. store1.com/checkout/onepage/ and store2.com/checkout/onepage/.
By using a UCC SSL certificate, the SSL will be valid for both domains and not cause you issues so no need for multiple IPs.