mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-02 14:36:17 +00:00
Fix .env Files for Isolated Users (#496)
This commit is contained in:
@ -2,19 +2,20 @@
|
||||
|
||||
namespace App\Actions\Site;
|
||||
|
||||
use App\Exceptions\SSHUploadFailed;
|
||||
use App\Exceptions\SSHError;
|
||||
use App\Models\Site;
|
||||
|
||||
class UpdateEnv
|
||||
{
|
||||
/**
|
||||
* @throws SSHUploadFailed
|
||||
* @throws SSHError
|
||||
*/
|
||||
public function update(Site $site, array $input): void
|
||||
{
|
||||
$site->server->os()->editFile(
|
||||
$site->server->os()->editFileAs(
|
||||
$site->path.'/.env',
|
||||
$input['env']
|
||||
$site->user,
|
||||
trim($input['env']),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user