protected function setHostIPAddressInEnv()
    {
        $host_ip = ProjectX::clientHostIP();
        $project_root = ProjectX::projectRoot();

        $this->taskWriteToFile("$project_root/.env")
            ->append()
            ->regexReplace('/HOST_IP_ADDRESS=.*/', "HOST_IP_ADDRESS={$host_ip}")
            ->appendUnlessMatches('/HOST_IP_ADDRESS=.*/', "\nHOST_IP_ADDRESS={$host_ip}")
            ->run();

        return $this;
    }