Towards the end of last year I was writing .net core AWS Lambda. I was super impressed with how .net core (and even PowerShell) works on Linux. I would have to say C# is by far my favorite programming language, the only exception might be T-SQL and the idea of being about to write code and get it to run on Linux is amazing. Mainly because Linux servers are, to be blunt, cheaper.
What I’ve done is:
Setup a virtual server on Civo, which is running Ubuntu. Created a c# dotnet core web api project Uses VSTS for version control, CI (automated builds) and CD (automated deployment). Used NGinx as a proxy LetsEncrypt for (free) an SSL certificate.
Currently I have 2 APIs, both only work for .UK domains and are under the https://seahorse.matt40k.uk/api namespace. They both return Json.
This uses the Nominet WHOIS2 service - its basically the standard WHOIS service only I can proxy - basically I pass the end-user IP rather then mine so I don’t eat into my own quote. The other thing I’ve done it to return the results as Json. https://seahorse.matt40k.uk/api/domains
For example: https://seahorse.matt40k.uk/api/domains/matt40k.uk
This basically queries the website for basic information. Url, domain name, if it has HTTPS, the generator tool used to create the webpages (using the Meta tag) - for example WordPress, etc, etc, etc https://seahorse.matt40k.uk/api/websites
For example: https://seahorse.matt40k.uk/api/websites/matt40k.uk
At some point I’m going to split it out into it’s own domain and look at setting up CloudFlare, however I haven’t quite decided how exactly to expand the project. I was working on updating the data on schools websites, however because of GDPR, Nominet has stopped publishing the owner of websites- which kinda put a stopper on my idea of pointing out how bad Nominet are when it comes to schools - hint, I found a large number of incorrectly registered school domains. For example, a number were registered as UK Individual. A schools domain should never be registered as to an individual.
If you find the APIs useful, let me know, or if there is anything that is broken or missing - drop me a tweet or email.