how to run ruby on rails program in ubuntu installed in vmware? - ruby-on-rails

I am trying to install ruby on rails on my windows. But after searching , I came to know that the best combination for ruby is either MAC or LINUX OS. But I m having laptop with windows 10. So can i install and run ruby and rails in UBUNTU inside VMware or which is the best option available?

Not sure what version of Windows 10 you have, but if you have the version that supports Hyper-V you have two good options.
http://vagrantup.com
Using either Oracle's Virtual Box or Hyper-V you can basically have a dedicated VM on your local box in the time it takes to download a pre-packaged box. I used this for a long time, though I now use http://c9.io as a cloud based IDE.

Step 1. Download the Oracle VM Virtual box from here.
Step 2. Download the Ubuntu ISO file. 64 bit Windows supports both 32 bit as
well as 64 bit guest OS. If your machine is a 64 bit machine then
download ubuntu-14.04.3-desktop-amd64.iso.
Step 3. Enable Intel vt-x from the BIOS menu.
Step 4. Disable Hyper-V platform from Turn windows features on or off.
Step 5. Insert the ISO image into the virtual CD/DVD drive as instructed here.
Step 6. Once the Ubuntu is installed on your VM. Install virtual box guest additions and it will be mounted inside the /media folder and at the right hand corner there will be a button to install the software and you're done with your setup.

Related

it is possible to install docker desktop on VMWARE ESXI?

it is possible to install docker desktop on virtual machine (vmware) windows 10 on a VMWARE ESXI ?
i am trying to install desktop docker on my vmware virtual machine with windows 10.
I installed the wsl2 support but at the end of the installation docker crashes with the following error:
Docker desktop 4.0.1
Installation failed
Component CommunityIstaller.ServiceAction failed to start services: The service did not respond to the start or control request in a timely fashion
I have done several tests but I cannot avoid this crash in any way.
The Operating System is a build that meets the minimum requirements to install Docker.
However, I noticed that Hyper-V is not enabled in the windows features. can this be a problem?
I think maybe it's a grafted virtualization problem because I install docker inside a VM. it's possible?
How can I solve? (or do you think that i will fix this problem with linux virtual machines?)
Does your host machine have all the advanced flags for 'efficient' nested virtualization? I wouldnt really recommend a third layer install of docker (as the final container is then virtual , on paravirtual (wsl2) on virtual (HyperV), on virtual (Esxi). I heavily assume the performance will be terrible.
And yes: You need Hyper-V, it's a requirement still. I assume, as you say its not available on the features, youre running a windows 10 home? Then sorry, you need at least Windows 10 Pro for Hyper-V support.
But as youre running a ESXI host, go the better performing way: Install any Linux distro of your choise, install docker there - if you wanna use it for Visual Studio etc. , you can still remotely debug etc. - and its performing better than on an a even deeper nested virtualized windows-wsl2. And btw: if its because of GUI, simply install the free Visual Studio Code, it offers Docker Tools which offer you many configiruation and monitoring options in a GUI , without enforcing you to do such a super deep nesting.
Yes, it's definitely possible. I'd probably check the hardware assisted virtualization (if available) is enabled. If so, you might want to make sure you've satisfied the rest of the requirements for the WSL2 backend deployment. If you're still having issues, try an older version and try upgrading from there.

Do I need Windows 10 Pro to run Docker? Error: Hardware assisted virtualization and data execution protection must be enabled in the BIOS

I just installed Docker after upgrading my Windows 10 Home x64 to the version 2004 with the OS build 19041.264 (I needed to upgrade because Docker required me to have an OS buld >19018). Now if I want to launch docker I get this error Hardware assisted virtualization and data execution protection must be enabled in the BIOS. I have already read this (it is old) question, but because they let me install docker on my windows 10 home I assume that I can somehow run it without hyper-v, cuz I can't download it.
The Hyper-V role cannot be installed on Windows 10 Home. Hyper-V is used to run Linux kernel on Windows.
https://learn.microsoft.com/en-us/virtualization/hyper-v-on-windows/quick-start/enable-hyper-v
The alternative solution is you can use Virtual box instead of Microsoft native Hyper-V. Docker toolbox comes with Virtual box. You can get details installation steps from below link.
https://docs.docker.com/toolbox/toolbox_install_windows/
You will need Windows 10 Pro to run docker. Home edition is not useful for the purpose.

Issues while installing Docker on Windows 10 home edition

I am getting below error When I try to install Docker on Windows 10 Home Edition.
[21:20:49.129] [InstallWorkflow] Pre-requisite failed: Docker for Windows requires Windows 10 Pro or Enterprise version 14393, or Windows server 2016 RTM to run
Can I Install Docker on Windows 10 Home Edition?
Edit Windows Version in Registry
Press Windows + R and write regedit
In the Registry Editor, go to \HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion
Right-click on EditionID and Click Modify
Change Value Data to "Professional"
Press OK.
Install Docker
After the installation, you can change the EditionID back to "Core"
As the error says, you cannot use Docker in the Home edition. You need "Windows 10 Pro or Enterprise version 14393, or Windows server 2016 RTM."
Check out their documentation here, which mentions, on 04/05/2018:
The current version of Docker for Windows runs on 64bit Windows 10
Pro, Enterprise and Education (1607 Anniversary Update, Build 14393 or
later).
As already mentioned in the comments, you might want to try the legacy Docker Toolbox:
Docker Toolbox is for older Mac and Windows systems that do not meet
the requirements of Docker for Mac and Docker for Windows.
Docker for Windows requires Hyper-V which is not included in Home edition.
You'll need to upgrade Windows to the Education or Pro edition.
https://docs.docker.com/docker-for-windows/install/#what-to-know-before-you-install
Also see this comment on GitHub.
You can already install Docker Desktop on Windows 10 Home.
This is how I did it:
You need to join Windows Insiders Program because you need WSL 2
You need to download the specific version of Docker Desktop: https://download-stage.docker.com/win/edge/41944/Docker%20Desktop%20Installer.exe which has a required change - allows install it on Windows 10 Home.
Those who have Windows Home Edition can now download and install Docker Desktop from below link.
https://docs.docker.com/docker-for-windows/install-windows-home/
Although not on Win10 Home per se, for evaluation purposes you can install Docker Desktop on a Win10 Pro virtual machine (VMWare player is my personal choice). You'll need to install VMWare Workstation Player which is free, and obtain a perfectly legal Win10 Pro image from microsoft directly here: https://www.microsoft.com/en-us/software-download/windows10
Be sure to activate the virtualization engine of the machine as Docker relies on Hyper-V:
This is how I resolved the problem. (OS- windows 10 home)
Join windows insider program. It enables you to update latest content of windows 10. You can find it in the start-> settings. Make sure to select Release Preview in the Insider program.(otherwise you will not get latest updates. After the installation you can pause frequent updates)
Check for windows update and update windows to latest version.(This will take awhile)
Install WSL 2 Linux kernel
https://learn.microsoft.com/en-us/windows/wsl/wsl2-kernel
I had below issue because I have tried to install this before updating windows. Please read the document carefully and follow steps.
If the installer cant find WSL 1 right click the Linux kernel update
installer, then press uninstall then rerun the installer
Now you are ready to update to WSL 2. Follow steps of this doc
https://learn.microsoft.com/en-us/windows/wsl/install-win10
Open PowerShell as Administrator and run:
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
Enable the 'Virtual Machine Platform'
Open PowerShell as Administrator and run:
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
Restart your machine to complete the WSL install and update to WSL 2.
You can verify whether this by looking at task manager.
*Set WSL 2 as your default version
In PowerShell: wsl --set-default-version 2
Now you can install docker desktop version.
Finally https://docs.docker.com/docker-for-windows/
This might not work for some. If you find any issues please post. I'll try to help.
This might help someone who cannot upgrade their system to pro or professional. Consider installing Docker Toolbox on Windows. For mac users: Docker Toolbox on Mac
Legacy desktop solution. Docker Toolbox is for older Mac and Windows systems that do not meet the requirements of 'Docker Desktop for Mac' and 'Docker Toolbox on Windows'. We recommend updating to the newer applications, if possible.
As per documentation, the toolbox includes these Docker tools:
Docker Machine for running docker-machine commands
Docker Engine for running the docker commands
Docker Compose for running the docker-compose commands
Kitematic, the Docker GUI
a shell preconfigured for a Docker command-line environment
Oracle VirtualBox
Get the latest update from https://www.microsoft.com/en-us/software-download/windows10 and it will work.
First of all I'd like to thank the previous respondents to this questions - saved me a lot of time and yes, they are both correct.
Secondly as a small completion to their answer, in case you are wondering where you can get a Pro version of Windows without breaking the bank, you can get a relatively cheap and legal Windows 10 pro cd-key from ebay and upgrade you version from Windows settings -> Activation.
https://www.ebay.com/sch/i.html?_from=R40&_nkw=windows+10+pro&_sacat=0&_sop=15
Just make sure you read the sold product description well and eventually the reviews if there are so that you know what to expect (if you encounter any issue, ebay will refund your purchase).
Best of luck to you all!

Delphi 6 Update 2 installation workaround on Windows 8.1 x64?

I need to work with Delphi 6 Update 2 in Windows 8.1 x64 (in case you were wondering, it's about maintaining an old application, migrating to a newer version is not an option. I can't use a VM because I use the same machine to connect to some peripherals that don't work in a VM).
The problem is that Update 2 has a 32 bit installer with a 16 bit stub. So the current behaviour is that the installer starts, it extracts the files in a temp location, starts the setup then nothing appears on screen.
So far, I gathered that it is impossible to do it. But the same behaviour I 've seen for SQL Server 2000 (don't ask) but there I was able to use msetup.exe (DemoShield) to open a sqlservr.dbd that started the script. However, there is no such dbd file. I guess I was lucky on SQLServer 2000.
So far I've tried compatibility mode, DosBox, replacing the setup file with both Installshield 3 and 5, waiting for hours for the setup to start (sometimes, W8 does that), even comparing files and registries on an XP machine before and after update 2 but this might be a bit too risky to apply on a real machine.
Since Windows 8.1 86 includes Hyper-V for running VMs, most modern hardware supports Hyper-V, and Windows 8 x86 can still run 16-bit based apps:
Install a Windows 8.1 x86 VM under your host physical machine, then install it there.
The up-tick: it is easy to move your VM to a new host without needing to reinstall a full new VM.
See http://www.techrepublic.com/blog/windows-and-office/get-started-with-windows-8-client-hyper-v-the-right-way/7893/ and http://www.infoworld.com/d/virtualization/5-excellent-uses-of-windows-8-hyper-v-208436 to get started with Hyper-V.
Hyper-V can redirect quite a bit of hardware from the host to the VM nowadays. For "old" hardware like COM and LPT ports you often can buy USB adapters that can be redirected.
If installing on x86 Windows 8.1 works and x64 fails, I think you have proved the assumption that the 16-bit portion of the installer is the culprit.
Maybe my blog post from last year can solve your problem:
http://blog.dummzeuch.de/2013/11/11/delphi-6-on-windows-8-1/
excerpt:
I just deleted the registry entry
HKCU\Software\Borland\Delphi\6.0\LM
(I did not make a backup, what would have been the point?)
I started Delphi 6, ignored the warning about incompatibilities (which was talking about Delphi 7 anyway) and went through the registration/activation process again. This time it worked.
Maybe I should mention, that I did not install any of my Delphi versions to c:\program files but put them into c:\Delphi instead to avoid any problems with access rights to the installation directory.

Developing Ruby Rails apps on small linux distro in Virtuablbox

I installed Ubuntu Desktop 12.04 LTS in VirtualBox on my Macbook Pro (i7, 4gb ram) in order to do development. Shockingly it's not very snappy (quick/responsive). I want to know which distributions of Linux are small/light but can be used for Rails development in Virtualbox.
Thank you
I did the same using Lubuntu (the light version of ubuntu) installed on a virtual disk. Moreover, I m using a portable version of VirtualBox to have everything on a usbstick.
I ran the Lubuntu from the usbstick and began to develop some rails apps but the OI was not that great for user experience so I copied the virtual disk with lubuntu on the harddisk together with the virtualbox folder. With this setup it work realy fine!
Also, I'm using the guest additions in order to keep shared folders on the usbstick to share the projects amongst machine.
Hope it can help you in your experience.
I use arch linux when developing. It is not designed with being “easy to use” as priority bu it is customisable for everything you need. I like the arch linux way.
Linux VM is not necessary for developing RoR apps on OSX.
Try to google on how to develop RoR apps on native OSX.

Resources