I am constantly requiring the use of multiple packages for my work, but alas my work PC doesn't have an internet connection. Hence, I am always stuck on downloading the package on a separate PC which has Ubuntu. I was wondering if it was possible to emulate my OS as RHEL6 and download the required packages to an rpm file via apt-get or something since most common answers to my problems seem to be answered in an apt-get install format.
You can use
Docker to spin up a CentOS 6 container. Then use
yumdownloader to download packages and their dependency RPMs.
If your work pc has a network connection to the ubuntu system, you may be able to solve by using an ssh forwarding.
ssh has the ability to act as a socks-proxy.
the first step would be
ssh -D localport ubuntu-server
since yum doesn't understand socks by itself you need tsocks to work around this step like described here How to use SOCKS proxy with yum?