Fix deploy package memory usage