How do I create sandbox environments on Mac OSX for running different program / projects? - macos

How do I create sandbox environments on Mac OSX for running different program / projects?
Let me envision a scenario for you. Say, I want to achieve three things from my computer simultaneously:
1) Work on an open source project that requires a particular set of configurations such as GCC4.6, Python 2.6 etc. to run / test etc.
2) Work on another open source project which gives its full functionality when running GCC4.8 or greater, Python 3.x etc. to run / test etc.
3) Listen to iTunes in the background.
Now, configuring the environment for the first two things is not easy and messes things up. What is even more hard is finding an intersection of combinations that can run both.
I achieve this by running VMWare and creating a new virtual machine for each open source project - configuring it to work with the project's requirements. However, this is not scalable. Is there a better way to achieve sandboxing?
I have a 2.53 GHz dual core processor with 16GB memory.

You might try Vagrant: https://www.vagrantup.com/ and install your Virtual Machine and work on that.
Further informations: http://docs.vagrantup.com/v2/why-vagrant/index.html
Hope it can be useful for you.

Related

How to run LibTool?

Currently I have tested my tool with clang-llvm installed on the machine I'm developing it on. All I have to do is go into build/bin to run my tool.
However, I now want to try running this tool on another machine.
What should I be doing here to run the tool I develop?
Do I have to setup the entire clang-llvm environment too? That's very time consuming and the entire folder is about 22+ GB in size..
The tool I'm creating is running RecursiveASTVisitor (same environment as the link below)
http://clang.llvm.org/docs/LibASTMatchersTutorial.html
Since you are just trying to run the tools on another machine, you can just transfer the whole llvm files and build files. IF you are running it on a different OS, you have to build the whole llvm and clang again as different OS (such as Windows) need extra tools such as cygwin .

how to check mac machine is busy with some taco build of cordova project on windows machine

My problem is that, I have 3 windows machines and 3 mac machines. I can make build on any mac machine using any windows machine using taco build command. Suppose Mac 1 machine is busy with windows 1 machine for making ios build. if windows 2 machine want to make build on mac 1 it should automatically switch on mac 2 or mac 3. Please let me know how I can do that.
I don't know if there's a great answer to this question. Here's just some suggestions - a couple things to consider:
Load Balancers - if you have the infrastructure in place, you can setup a load balancer to front the multiple different mac build machines. Then, point your windows machines to that load balancer.
Consider a third party solution like http://www.macincloud.com/.
Consider a third party build solution like using VSTS to build your source for IOS. https://msdn.microsoft.com/en-us/library/vs/alm/build/xcode/xcode-projects
Point your individual Windows machines to their own individual mac build machines.

Use of an IDE when my server is on a VM

I mostly develop in PHP, but I'm using Python and Ruby more and more. I edit the code in my OS (I'm on a Mac, so OS X Snow Leopard), but my server is on a VM (VM Fusion).
I use the IDEs mostly for their syntax checking - something TextMate, Espresso, et al, are not so good at. However, I can see that all these IDEs have vastly more power than syntax checking, but I'm not using it because the server is a VM.
For example, being able to set breakpoints and step through code. I've used these features with JavaScript, so I know how useful they are, but I can't use them because my server is on a VM instead of running natively inside the same OS as the IDE.
Is there a way of taking advantage of all these powerful features, without either developing inside the VM or running the server in Mac OS X?
I don't know what sort of server you have that couldn't be run natively in Mac OS X for development -- pretty much anything would work great. Alternatively, you can run the IDE in the VM along with the server -- desktop apps work just fine in VMWare too. So you have two excellent alternatives facing you -- do whichever one is easier!

Using Time Machine for test environment rollback for Mac platform

When I'm testing software I'm going to deploy or running through tests in the Windows world, I'll use VMWare images so that I can start from a fresh, known state at the beginning of each test. This has worked really well so that I can install software on different OS flavors or with other/different apps and drivers loaded. This makes it super simple to duplicate or nearly duplicate a customer's environment when addressing issues that crop up.
Now I'm tasked with doing something similar for Mac OS X. I'm far less familiar with this OS and didn't really see the same sort of thing available. I noted that the server version of 10.5 might allow this, but I'm not running that here. I've got access to 10.5 on a Mac Book and one of those Mac Minis.
Has anyone used Time Machine to put their test Mac box into a known state? Or do you have other ideas? I'm also interested in a solution for 10.4 since some of my customers run "Tiger".
I tend to test things that don't manipulate the global computer state (i.e. a lot of well written Cocoa applications) with the "Guest" account. Since Tiger (I think), the effects of using this account are wiped at logout, so you can easily get a virgin environment again.
By default, Time Machine excludes certain paths from backup. This could be detrimental to your testing strategy, depending on the system resources that your software touches. See this article for information on the exclusions. At a bare minimum, if you are going to use Time Machine to rollback, make sure nothing you are testing depends on any of the excluded files.
But, I think there is a better alternative, if you can live with Mac OS X Server: VMWare Fusion provides support for virtualizing instances of Mac OS X Server Leopard. Then you can use the same strategy you used for Windows.
From http://www.vmware.com/products/fusion/features.html
VMware Fusion boasts the most complete
OS support, supporting more than 60
operating systems in a virtual
machine, including Windows XP, Windows
Vista, and even Mac OS X Server.
Keep in mind, you cannot virtualize Mac OS X Client due to license restrictions, though.
An alternative (perhaps more lightweight) solution that I just found recently is an app called RooSwitch. It lets you swap configurations for an application. So you could have a bunch of different prefs files, cache files, etc for your app and create a named configuration for it. You can create multiple configurations to test new user setup, or to reproduce an issue using a customer's data without losing your own config. RooSwitch then lets you switch between all these different configs.
I haven't used it myself yet, but heard about it on a podcast recently and thought it sounded useful for my own development and testing.

How to create a LIVE CD for an Application

There are Live CDs that boot up an OS and allow you to use it without installation.
I was wondering if there is an easy way to customize a Live CD so that it only loads what is necessary to run one application, and runs that application.
With Ubuntu I used the Ubuntu Customization Kit to customize an Ubuntu Live CD that loaded the stuff I needed by default in my computer.
For some values of "easy way" yes, but in most cases no.
If the required OS is Windows, you'll find a lot of information if you check out BartPE. You'll have licensing problems if you don't understand that you can't distribute windows OS, even on a livecd, without MS licenses for each copy.
Linux livecds are a little more complex to create, but there are many people making the process easier, http://www.linux-live.org/ is a great resource to get started.
-Adam
That depends what you mean by "easy way". If you're comfortable installing and administering an OS to be secure and stable, you shouldn't have much trouble creating a LiveCD for that OS with the software you need installed and auto-running. Much more detail depends very much on the OS and type of application you're trying to run.

Resources