Best way to work on a dev. server in the same datacenter?
What are your procedures for rolling out a development server and moving those changes to production? Any tips, step-by-step checklists, etc. would be greatly appreciated. Thanks.
5 Replies
2) Setup a VM
3) Istall the same Distro and Apps that run on your Linode in the VM
4) ,
5) Profit…er Develop
Is there really any reason to dev on a public hosted system?
RAM is dirt cheap (more or less), add another 4gig to your Desktop and voila! there's your dev server.
Plus, with this method you have the bonus of KNOWING your code is transportable (and your install Doc's are current and up-to-date), since you'll have to move it from your inhouse dev VM to your public facing Linode to go live.
@yaz:
My hematology, oncology, and chemotherapy regimen wiki
Cool!
@yaz:
I'm an amateur and figuring out things as I go along, and I've reached the point where I'd like to try to try some additional things out on my installation. Since I may make mistakes, I'd like to do this on a development server rather than the actual production server, since there are people who are using my sites. What's the best way to do this and what do you all do? My current plan is to create another Linode within the same datacenter, copy over all the data, and develop on the new server. I'm a little unsure of the details; for example, would another Linode within the same datacenter have the same or different IP address? If it's different, that would make it easy to just update logs & databases, then swap IP addresses when everything is done.
What are your procedures for rolling out a development server and moving those changes to production? Any tips, step-by-step checklists, etc. would be greatly appreciated. Thanks.
Linode is really setup for people that know Linux pretty well. A lot of us do this for our day job so it's practically second nature. This forum is pretty helpful most of the time.
What I'd suggest is getting a second linode and setting it up identically to the first. The easiest way to do this is to use the clone tool in the Linode manager. It will let you clone your config and disks to a new Linode with a new hostname and IP. It's faster to clone to a new Linode in the same data center but it's not a requirement, the new one can be anywhere. Then boot the config on the new Linode and change all references to the now changed IP and hostname.
Then play away changing whatever you like. When you are happy just update your DNS so your live hostname resolves to the new server. You don't need to change IPs on linodes, just update DNS so your live internet name resolves to the new server.
You could alternatively do development on your home machine and save yourself the cost of a second Linode but then you don't get the cool clone tool and you need more downtime to move from development to production. Plus bandwidth is pooled between all Linodes you own although if you are running one website you likely don't need double the bandwidth.
@vonskippy:
1) Setup VirtualBox on whatever OS you use on your Desktop
2) Setup a VM
3) Istall the same Distro and Apps that run on your Linode in the VM
4) ,
5) Profit…er Develop
Is there really any reason to dev on a public hosted system?
I understand what you're saying. Rolling out a new server locally would ensure that my documentation–which I have been doing, but is more topical rather than a perfect step-by-step--and backup strategies are robust enough to allow me to recover from a total disaster. I could have a nice local copy to develop on and push updates out with as I wish. However, the benefits would be as sednet points out: namely speed and ease of getting this dev server running and making it live. I regularly make multiple offsite backups of my most important data--my wiki's database--but I'm still figuring out on my own the best way to maintain updated offsite backups of my entire server, which will probably involve Rsync. The question for me is whether the time, effort, and immediate security to test out my disaster recovery plan now is worth the trade-off in convenience at this time rather than a few months in the future, when I anticipate having more free time to learn these things.
@sednet:
@yaz:My hematology, oncology, and chemotherapy regimen wiki
Cool!
Thanks!
@sednet:
What I'd suggest is getting a second linode and setting it up identically to the first. The easiest way to do this is to use the clone tool in the Linode manager. It will let you clone your config and disks to a new Linode with a new hostname and IP. It's faster to clone to a new Linode in the same data center but it's not a requirement, the new one can be anywhere. Then boot the config on the new Linode and change all references to the now changed IP and hostname.
Then play away changing whatever you like. When you are happy just update your DNS so your live hostname resolves to the new server. You don't need to change IPs on linodes, just update DNS so your live internet name resolves to the new server.
Thanks, I think this makes more sense than my plan that had the extra IP swap. The big task would be for me to make sure all IP-related references are changed appropriately. I don't know if, for example, the IP data is populated automatically in some config files, and I'm not confident in my ability to find all of them without some error messages popping up.
@obs:
If you only have one IP address then by default Linode uses DHCP to configure it so you're fine there. Unless you've manually entered your IP somewhere you won't need to change anything except the hostname
:)
Plus if you clone from a live to a dev server you will find everything that needs to be updated just getting the dev server running. It might be just iptables rules and /etc/hosts if everything else binds either all addresses or localhost.