remove Logs::
This commit is contained in:
parent
9321cc3de8
commit
98d057a2ac
@ -25,7 +25,6 @@ public function create(array $input): User
|
||||
{
|
||||
$settings = InstanceSettings::get();
|
||||
if (!$settings->is_registration_enabled) {
|
||||
Log::info('Registration is disabled');
|
||||
abort(403);
|
||||
}
|
||||
Validator::make($input, [
|
||||
|
@ -66,7 +66,7 @@ protected function loadRepositoryByPage()
|
||||
}
|
||||
protected function loadBranchByPage()
|
||||
{
|
||||
Log::info('Loading page ' . $this->page);
|
||||
ray('Loading page ' . $this->page);
|
||||
$response = Http::withToken($this->token)->get("{$this->github_app->api_url}/repos/{$this->selected_repository_owner}/{$this->selected_repository_repo}/branches?per_page=100&page={$this->page}");
|
||||
$json = $response->json();
|
||||
if ($response->status() !== 200) {
|
||||
|
@ -43,7 +43,7 @@ public function handle(): void
|
||||
$this->application->save();
|
||||
}
|
||||
} catch (\Exception $e) {
|
||||
Log::error($e->getMessage());
|
||||
ray($e->getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -48,13 +48,14 @@ public function handle(): void
|
||||
}
|
||||
}
|
||||
} catch (\Exception $e) {
|
||||
Log::error($e->getMessage());
|
||||
ray($e->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
private function get_disk_usage(Server $server, string $docker_root_filesystem) {
|
||||
|
||||
private function get_disk_usage(Server $server, string $docker_root_filesystem)
|
||||
{
|
||||
$disk_usage = json_decode(instant_remote_process(['df -hP | awk \'BEGIN {printf"{\"disks\":["}{if($1=="Filesystem")next;if(a)printf",";printf"{\"mount\":\""$6"\",\"size\":\""$2"\",\"used\":\""$3"\",\"avail\":\""$4"\",\"use%\":\""$5"\"}";a++;}END{print"]}";}\''], $server), true);
|
||||
$mount_point = collect(data_get($disk_usage, 'disks'))->where('mount', $docker_root_filesystem)->first();
|
||||
return Str::of(data_get($mount_point, 'use%'))->trim()->replace('%', '')->value();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user