That is a question for the DEA. Presumably if you have a DEA number assigned to your name, you should be able to use it for prescribing anywhere. Your patients can take your prescriptions to a civilian pharmacy if they want. If you have an institutional number, as you might as a resident, then your use of that number might be limited to prescribing done as part of work for your institution, but not elsewhere, say as a moonlighter. I don't think you are prevented from applying for a DEA number apart from your institution. The only issue would be paying the fee, which might not be waived if you already have a no-fee number for federal/state institutional use.