sand it first, pine will suck in you stain so depending on how dark or light you want it you will probably have to find out what base you stain is and water it down, or seal you cabinet first with varnish or something then aply your stain lightly untill you get it the coulour you want.
Get a good marine varnish to cover after the stain, if stained pine gets wet the stain will look uneven and the wood could start to warp particularly with the help of the weight of the tank.