The VMware Cloud native team introduced two exciting new open source projects last week called Project Photon and Project Lightwave that will help customers securely build, run, and manage their cloud native applications. For more information on the project launch see the following Press Release.
Project Photon is a lightweight Linux operating system for cloud-native apps. Photon is optimized for vSphere and vCloud Air, providing an easy way for our customers to extend their current platform with VMware and run modern, distributed applications using containers. Project Lightwave is an extensible directory server that supports authorization and authentication for containers, users, and any other resource. When paired with Project Photon, Project Lightwave ensures that only authorized objects can run in the infrastructure.
The exciting project to talk about in this blog post is VMware Photon which makes it really easy for teams to build containerized applications – from developer desktop to production – and blend them seamlessly into existing VMware environments. The team in the Cloud Native group created a great website talking about Project Photon, Getting the Photon ISO, and How to Get Started/Installed. The Photon Website is located at http://vmware.github.io/photon/
While there is a step by step Photon Getting Started Guide for VMware Fusion, the steps and installation screenshot are from VMware Fusion running on a Mac (Default Development Computer at VMware). Luckily the majority of the steps can be transposed to VMware Workstation which I have highlighted below for the purpose of testing and education of Project Photon.
Note: Not all steps are listed below since the Photon Getting started guide for Fusion does a great job of walking you through the Photon installation after the VM is created since the steps are identical in Fusion and Workstation.
Installing VMware Photon in Workstation
1: Download Photo ISO
Download the latest Photon ISO from here or clone the GitHub Photon repository and make the ISO using the instructions found on the GitHub repo
2: Install Photon from an ISO Image.
On the Workstation Home Tab click “Create New Virtual Machine” or go to Menu - File and select “New Virtual Machine”.
The New Virtual Machine Wizard will pop up and select “Typical” configuration and click Next
Choose “Install from” method and Select “Installer disc image file (iso)” then browse to the Photon ISO location and select the ISO. At this point Workstation will not recognize the new guest operating system but click Next to continue to manually select the operating system.
Select “Linux” Guest Operating System and from the pull down menu select “Other Linux 3.x kernel 64-Bit” and click Next to continue.
Provide Name and location for the Photon virtual machine and click Next.
For the next step accept the default disk size shown for this example and select store the “Store virtual disk as a single file”. Depending on your application running in the container you would adjust the virtual hard disk size as appropriate. Click Next to continue.
The “Ready to Create Virtual Machine” Summary Box will displayed. Before finishing the Photon Virtual Machine Creation, we strongly recommend that you customize the Virtual Machine and remove any unwanted devices that are not needed for a container runtime environment by clicking the “Customize Hardware…” Button
Once you click on “Customize Hardware…” Button a new dialog box will be displayed. We recommend that you remove or uncheck the following components if they show up: Printer, Sound Card, Camera, Bluetooth, 3D acceleration. To remove or modify the device settings click the default installed device and either uncheck the feature or remove the device. Also at this point you would adjust the memory and processor settings based on your application running in the container but for this example we will accept the default size. Click the Close button to return back
At this stage we have made all the necessary customizations and we are ready to begin the installation process. Click Finish and you will be taken back to the newly created Photon Virtual machine that is ready to be powered on.
3: Running the Photon Virtual Machine
Now select the Photon Virtual Machine and press the “Play” button to power on the host and start the Photon Installation process.
Within a few seconds the Project Photon Installer Boot Menu will appear.
4: Photon Installation in the Virtual Machine
For the sake of not creating a even longer blog post you can continue to follow the step by step Photon installation instructions on Page 8 of the Getting Started Guide for VMware Fusion or follow along in the “Use VMware Fusion to get started with Project Photon container runtime” video on YouTube at about 2:35 into the video.
After you have successfully completed the Photon Installation you are ready to use your container runtime environment. Upon the next reboot/restart you will be come to a login prompt and you are ready to go.
5: Installing Application in Container
At this point you can install a Containerized Application from the Docker Hub or your own containerized application since a command prompt is not that exciting. If you return to the Photon installation instructions on Page 15 of the Getting Started Guide for VMware Fusion there is a example of Installing a Containerized Web Server (Nginx) Application to Help Demonstrate Capability of Project Photon. Below is the final screenshot of a Web browser connecting up to the Nginx web server running in the Photon container.