Moved this site to Cloudflare Pages

 Triviality  Comments Off on Moved this site to Cloudflare Pages
Mar 202025
 

This site is current on Cloudflare Pages, it does not make sense to have a dedicated VM running web server to serve static page only (I could not run full blog on GCE VM as free tier is too weak).

I checked several alternatives, turned out AWS and Cloudflare are the best in this area, I chose Cloudflare as it is free, I know there may be something change in the future but anyway this is not a critical piece to me so I can afford at least several days of downtime if I have to switch to something else.

I’m going to shutdown GCE VM after verify everything’s working fine, I don’t think I have anything left over that tiny box.

Migrate domains to CloudFlare

 Triviality  Comments Off on Migrate domains to CloudFlare
Jan 072024
 

I’m cheap ๐Ÿ™‚

Route 53 charges $0.50 per hosted zone per month on top of domain registration, it becomes a significant portion after I downgraded S3 storage class to Glacier IR, after looking around I moved all domains to CloudFlare.

The only concern for now is that CloudFlare is still young and losing money, people showed their concern that CloudFlare may change its pricing modal in the future, but I think I can worry it later when it happens, as none of these domains are critical to me now.

Also I migrated WordPress site to Mac under UTM, still with simply-static.

Sep 232017
 
aws route53 change-resource-record-sets --hosted-zone-id $(aws route53 list-hosted-zones | grep -B 1 '"xiehang.com."' | grep '"Id"' | cut -f 4 -d \" | cut -f 3 -d /) --change-batch file://<(echo '{"Changes":[{"Action": "DELETE","ResourceRecordSet":' $(aws route53 list-resource-record-sets --hosted-zone-id $(aws route53 list-hosted-zones | grep -B 1 '"xiehang.com."' | grep '"Id"' | cut -f 4 -d \" | cut -f 3 -d /) --query "ResourceRecordSets[?Name == 'to-be-deleted.xiehang.com.']" --max-items 1| egrep -v '^\[|^\]')'}]}')

Or as a script:

ZONE_ID=$(aws route53 list-hosted-zones | grep -B 1 '"xiehang.com."' | grep '"Id"' | cut -f 4 -d \" | cut -f 3 -d /)
RECORD=$(aws route53 list-resource-record-sets --hosted-zone-id ${ZONE_ID} --query "ResourceRecordSets[?Name == 'to-be-deleted.xiehang.com.']" | egrep -v '^\[|^\]' --max-items 1)
JSON='{"Changes":[{"Action": "DELETE","ResourceRecordSet":'${RECORD}'}]}'
aws route53 change-resource-record-sets --hosted-zone-id ${ZONE_ID} --change-batch file://<(echo ${JSON})

 

Jul 062014
 

I’m working for the big chip company now, sound a little bit weird, though ๐Ÿ˜‰ .

Anyway, I’m sitting in backend team focusing on DevOps, I guess I will be in this mixed role till we find a dedicated DevOps guy. I guess whenever that happens, I’ve already finished monitoring facility (plus logistical stuffs like on-call schedule, etc.), and should have finished the plan to migrate from Rackspace to AWS.

Everything works smoothly so far except git – I admit current company is using git in a modern way, but I don’t think previous company was doing something wrong. Anyway, I believe people do have different ideas of how to use git, I just have to fit into the company’s style.

I don’t quite like saltstack although I’m still trying to get familiar with it. However, before I raise this as a concern to the team, I’d like to make sure everything that saltstack is doing can be done by cfengine.

Ah yea, also need to evaluate Shinken as it’s a pure Python solution, and “we are a python house”.

Jul 062014
 

Trying to merge everything running on AWS to a single instance, and once the instance is good enough to run all my stuffs, will book a reserved instance to save cost.

It seems I’m having less and less sites up and running, I got impression that I used to have 10+ sites flying around for random purposes but now I have only 2 “serious” sites. Sure I still have 2 or 3 sites running test environments but they can be discarded anytime.

The company is moving to AWS as I was told, could be a good time to start look around things like VPC, etc.

 Posted by at 13:55  Tagged with:
Nov 072012
 

Just upgraded Xcode to 4.5.2 through App Store, which has iOS6 support, I don’t know what else this new version includes though …

And after the upgrade, I got some time playing with previous AWS project which list my stuffs on AWS, include S3 and EC2. Obviously, every time I access my old codes I could find something wrong, and there is no exception this time – at the time I was doing AWS project, I had only 2 instances staying in one region, and now I have multiple (5?) instances staying in two regions so previous logic does not work very well.

Not many details to talk about here, I simply list all regions for AWS, and query instances targeting each endpoint, that’s it.

Now my AWS app is working well again.