add environment and spec