The Government of Canada has some decent policies on that. The Directive on Management of Information Technology stipulates that government agencies must:
* Favour open source solutions * Favour non-prorietary solutions * Release source for custom-built solutions under open source licenses through Government of Canada sites
See C.2.3.8 for the relevant clauses: https://www.tbs-sct.gc.ca/pol/doc-eng.aspx?id=15249