modify deploy routine