Follow the installation guide from here: http://openacs.org/doc/openacs-4/
Information on virtual hosting can be found here: http://www.theashergroup.com/tag/articles/nsvhr/virtual-hosting-howto
If you just want to serve different domains from one instance of OpenACS, e.g. same DB, same users etc. then also check out the host-node-map stuff that is included in OpenACS-4 in the subsite package.