install gnome on ubuntu server code example
Example 1: install gui in command line linux
sudo apt-get install ubuntu-desktop
Example 2: apt install gnome desktop
sudo apt install gnome-session gdm3
sudo apt-get install ubuntu-desktop
sudo apt install gnome-session gdm3