Ubuntu 22.04 Jammy Jellyfish was revealed in April this 12 months. Ubuntu customers are enthusiastic about its superior desktop options, resembling assist for Wayland and GNOME 42 (I’ll use SliM this time since I received’t play any sport on this demo). However just lately, some Ubuntu customers say that they will’t launch the Jammy Jellyfish desktop in Google Cloud by following my earlier weblog: Launch Ubuntu Desktop on Google Cloud. That’s too dangerous as a result of Google Cloud offers Ubuntu customers such a seamless expertise by means of Chrome. Don’t fear, you’ll be able to proceed utilizing Chrome entry to your Ubuntu Desktop on Google Cloud. Simply comply with this text.
We’d like 4 steps to arrange a Ubuntu digital machine with a graphic interface, similar to your desktop surroundings by yourself laptop:
- Create a Ubuntu VM occasion on Google Cloud.
- Set up and configure the Chrome Distant Desktop service on the VM occasion.
- Arrange a Ubuntu desktop surroundings within the VM occasion
- Join out of your Chrome internet browser to the desktop surroundings on the VM occasion.
Earlier than you start:
- Just remember to chosen a Google Cloud mission for operating this VM occasion.
- Should you don’t have the Google Chrome browser put in, you’ll be able to set up it from the Google Chrome homepage.
Create a Ubuntu VM occasion
On this step, we are going to launch a VM occasion in Google Cloud. The default e2-medium (2 vCPU, 4 GB reminiscence) machine sort works high quality for a tutorial function. If you’d like a extra performant machine, there are a selection of decisions in Google Cloud.
1. Within the Google Cloud Console, go to the VM Situations web page:
2. Click on CREATE INSTANCE.
3. Set the occasion identify to a singular identify you want. Should you don’t have any occasion in your mission, Google Cloud will assign you a default identify “instance-1”, which I’m high quality with this time.
4. Choose a area and zone you need to run your occasion.
5. Scroll all the way down to the Boot disk choices and click on Change
6. Within the Boot disk pop-up window, in Working System, choose Ubuntu Professional from the drop-down; in Model, choose Ubuntu 22.04 LTS Professional Server; maintain the remaining choices as default worth and click on SELECT. Ubuntu Professional ensures the most recent safety replace, which will probably be helpful once we set up manufacturing purposes.
7. Click on CREATE to create the occasion.
8. In lower than one minute, it is possible for you to to see your Ubuntu occasion in RUNNING standing. You possibly can click on the SSH button within the occasion listing to hook up with your new occasion.
Should you favor to start out a VM by means of Google Cloud Shell, you need to use this command to attain the identical consequence:
gcloud compute situations create instance-1 --zone=us-central1-a --machine-type=e2-medium --image=initiatives/ubuntu-os-pro-cloud/world/photographs/ubuntu-pro-2204-jammy-v20220923
Set up Chrome Distant Desktop on the VM occasion
The subsequent step is to put in Chrome Distant Desktop on the VM occasion. Obtain and set up the Debian Linux Chrome Distant Desktop set up package deal:
wget https://dl.google.com/linux/direct/chrome-remote-desktop_current_amd64.deb
sudo apt-get set up --assume-yes ./chrome-remote-desktop_current_amd64.deb
Arrange a Ubuntu desktop surroundings within the VM occasion
Now we have to set up a desktop surroundings and window supervisor for Chrome Distant Desktop to speak with the VM occasion.
1. Within the SSH window linked to your VM occasion, refresh the repository and package deal lists, and carry out the mandatory upgrades with the next command:
sudo apt replace && sudo apt improve
2. Set up and arrange Show Supervisor. Right here I take advantage of SLiM for its light-weight function.
sudo apt set up slim
3. Set up Ubuntu desktop surroundings (the set up course of might have round 20 minutes):
sudo apt set up ubuntu-desktop
4. As soon as finishes set up, reboot the machine:
sudo reboot
5. You’ll lose connection whenever you reboot. SSH into the digital machine once more and begin SLiM:
sudo service slim begin
Configure the Chrome Distant Desktop service and Connect with your Ubuntu Desktop
To begin the distant desktop connection, you must have an authorization key on your Google account.
1. In your native laptop, utilizing the Chrome browser, go to the Chrome Distant Desktop command line setup web page:
https://remotedesktop.google.com/headless
2. On the Arrange one other laptop web page, click on Start.
3. Click on Subsequent. You already put in the Chrome Distant Desktop on the distant laptop in STEP2.
4. Click on Authorize.
5. Now you get the command to arrange and begin the Chrome Distant Desktop service in your VM occasion. Copy the command for Debian Linux.
6. Paste the command to the SSH window that connects to your VM occasion. Run the command.
7. Enter a 6-digit PIN when prompted. This PIN will probably be used whenever you log into the VM occasion out of your Chrome.
8. In your native laptop, go to the Chrome Distant Desktop website online. One can find your Ubuntu Desktop exhibits up within the portal.
9. Click on the distant desktop occasion. On this case, it’s “instance-1”. And you’ll be prompted to enter the 6-digit PIN you set in step 7.
10. You will notice this web page, simply cancel it.
Now, Ubuntu desktop is totally purposeful in your Chrome internet browser:
Set up an app in your Ubuntu Desktop
Let’s set up the Chromium internet browser, the open-source model of Chrome, from the Snap Retailer. In your terminal, run:
sudo snap set up chromium
You need to use Chromium “inside” Chrome in lower than a minute:
Clear up
To keep away from incurring expenses to your Google Cloud account for the sources utilized by this tutorial, it’s possible you’ll delete the VM occasion.
Within the Cloud Console, DELETE this VM occasion:
Then in your Google Chrome Distant Desktop, DELETE the “Distant system” (“instance-1” in my case) out of your Distant Units listing.
That’s it. Take pleasure in your Ubuntu 22.04 Jammy Jellyfish Desktop wherever anytime!