turrets currently have three modes : forward fire, target only, and fire at will.
Forward fire: All turrets behave like fixed weapons, meaning they aim forward with minimal tracking like with fixed weapons.
Target Only: Will track and fire at your selected target, even if they move out of your field of view, as long as the turrets can get a firing solution. (target must be hostile,thus unless a station is already hostile, then no the turrets will not fire on the station)
Fire-at-will: All turrets will track their own targets as long as they are hostile. Note; This does not mean they automatically return fire for some odd reason. As of right now they will only automatically fire at hostile targets at CZs as far as i can tell. Any other time you would have to manually engage the enemy(ies) first before your turrets start tracking and firing. Whether that be using a non-turret weapon, or your turrets in fixed firing mode.
Note: When turrets are on "Fire at will" mode, you will not incur friendly fire penalties nor will you incur bounties when they fire at a neutral ship if the ship blocks fire. Basically the game absolves you of responsibilities in the sense that you are not in control of what your turrets hit.
No, they will not fire when not deployed because they are still in the interior of your ship, and firing in this scenario would likely cause unwanted damage as your turrets try to reach the enemy though your ship from the inside.
As for deployment, they do not automatically deploy, as they are considered weapon hardpoints.
Also, when outfitting your turrets, note where they are located on your ship, as turrets can only hit what they have a line of fire at. As in, if the turret is placed on the upper hull of your ship, then it can't fire at what is under your ship. Imagine drawing a straight line from your turret and your target, if there is anything in the way, the turret won't fire.