In this paper we consider a class of stochastic evolution equations arising from initial boundary value problems with both boundary and distributed noise. We prove existence and regularity of mild solutions. Then we consider a controlled version of the model and prove the existence of optimal controls and develop the necessary conditions of optimality for partially observed problems using relaxed controls.