I agree with Hooded. When someone is moving away is not the time to suddenly dump your feelings on her. Writing a song for/about her is too personal if you don't already have a close relationship.
However, you could do something in more general terms. Tell her the fact that she's moving away is making you realize how things can change on you and now you're wondering how many other people you know are going to drift away and become part of your past. And you're hoping maybe you could stay connected to some extent, maybe on Facebook, Instagram, Google+ or whatever and--if she declines--drop it, don't push it.
If you write a song, make it about how time passes, things change, opportunities drift away before you take advantage of them...something like that.