Ubuntu is a Linux distribution, it is just a piece of software (an operation system) , on it's own -- it can't mine anything, let alone BTC.
So what is the hardware you got? if it is not an ASIC then it won't be able to feasibly mine BTC, if it is an ASIC then all ASIC miners come equipped with an operating system.
I have a intelcore i7 with a rtx 2060ti, its good?