Consider two regular integral proper algebraic surfaces $X$ and $Y$ over a DVR $\mathcal O_K$ with residue field $k$. Let $U \subset X$ be an open subset, s.t. $X\setminus U$ consists of finitely many closed points lying in the closed fiber $X_k$. Assume that all points in $X\setminus U$ considered as points in $X_k$ are regular. Consider now an $\mathcal O_K$-morphism $f: U \to Y$.
Is there any extension of $f$ to $X$?
I know that $Y_k$ is proper. Since every $x \in U_k$ is regular, $\mathcal O_{X_k,x}$ is a DVR, therefore by the valuative criterion of properness $ Hom_k(U_k,Y_k) \cong Hom_k(X_k,Y_k), $
so $f_k$ can be uniquely extended to $X_k$. Thus, set-theoretically an extension of $f$ exists.
On the other hand, if there is an extension of $f$ to $X$, then on the closed fiber it coincides with $f_k$. Unfortunately, I don't see, how to construct such an extension scheme-theoretically.
Motivation
Consider a subset $\mathcal C$ of the set of irreducible components of $Y_k$. Assume that the contraction morphism $g: Y \to X$ of $\mathcal C$ exists, i.e. $X$ is proper over $\mathcal O_K$, $g$ is birational and $g(C)$ is a points if and only if $C \in \mathcal C$. Since $g$ is birational we have a section $f: U \to Y$ of $g$ over an open $U \subset X$. In fact, $X\setminus U = f(\mathcal C)$. If we now assume that all $x \in X\setminus U$ are regular as points in $X_k$, we will obtain the above situation.