VDI Best Practices

Ansible

Managing your own company emails, meetings, applications and then additionally those within the VDI (Virtual Desktop Infrastructure) session for the customer you are working with can be a struggle.

Below are some tips and tricks while using a VDI session.

Meetings

Configure forwarding of meetings to your main email address and calendar system. This ensures one central view of your meetings.

  • Open Outlook
  • Navigate to File -> Manage Rules & Alerts menu
  • Select New Rule ...
  • Select Apply rule on messages | receive and click NEXT
  • Select which is a meeting invitation or update and click NEXT
  • Select Yes to confirm
  • Select forward it to "people or public group", and then click the hyperlink people or public group in the box below and add provide target email address in the TO field and click OK
  • Click NEXT
  • Click NEXT
  • Specify the rule name, for example “Forward to Red Hat”
  • Click FINISH

Development

If you intend to do some development work within a VDI session, you’ll most likely need to setup SSH, code editor, and ultimately be able to clone a repository from a version control system to begin your work.

Most of these instructions can be completed even if you do not have administrator access within your VDI environment. Simply install apps into a shared folder. Some folders will be emptied upon restart of your VDI session so be sure you find the right folder to use.

SSH Client

Install the Home Edition (free) of MobaXTerm. It is a multi window SSH client that is really easy to use.

Note that you might need to install the Portable Edition which has the software inside a single folder and does not require administrator access to the machine.

Code Editor

My editor of choice currently is Visual Studio Code. Here’s how to install it and configure it to pull code from a repository using either HTTPS or SSH authentication.

  • Desktop
    • Install Git for Windows, with all default installation options
    • Install Visual Studio Code, with all default options
    • Start Git Bash command window
    • Run ssh-keygen with default values to create your private key file
    • Run cat .ssh/id_rsa.pub to show the public key
  • BitBucket
    • Navigate to BitBucket using your browser
    • Navigate to top-right icon and click on Personal Settings in BitBucket
    • Navigate to SSH Keys section, add the public key in there
    • Navigate to an exiting repository in BitBucket you want to clone
    • Copy either the SSH url or HTTPS url
  • Configure Git
    • Start Git Bash command window
    • Run git config --global http.sslVerify false (required to connect via HTTPS instead of SSH)
    • Run git config --global user.name "First Lastname"
    • Run git config --global user.email "email@this.com"
    • Run cd; mkdir repositories to prepare a subfolder for just your git repos
    • Run cd repositories
    • Clone existing repo by running git clone <repo>
    • Clone any other repos you wish to work on
    • Run code . to launch Visual Studio Code window with all the existing repo folders showing up for you
  • Last Steps
    • Add/install VSCode extensions (Ansible, Jinja, etc)
    • Restart VSCode
  • Done!