use env in safe exec