As you may know, Adobe Flash is not the safest thing on the internet this days. Mozilla even disabled it from the Firefox browser a while, due to the vulnerabilities found lately.
But to avoid Flash on your browser, you can use MPV, the lightweight media player based on MPlayer.
First, install MPV on your Ubuntu system:
$ sudo add-apt-repository ppa:mc3man/mpv-tests
$ sudo apt-get update
$ sudo apt-get install mpv
And after that, install the MPV browser extension.
From now on, when you will be YouTubing, press the Play with MPV button on the top-right corner.
The installation instructions should work on Ubuntu 15.04 Vivid Vervet, Ubuntu 14.04 Trusty Tahr, Ubuntu 12.04 Precise Pangolin and derivative systems like Linux Mint 17.2 Rafaela, Linux Mint 17.1 Rebecca, Linux Mint 17 Qiana, Linux Mint 13 Maya, Pinguy OS 14.04, Elementary OS 0.3 Freya, Elementary OS 0.2 Luna, Deepin 2014, Peppermint 6, Peppermint 5, LXLE 14.04 and Linux Lite 2.