改名
This commit is contained in:
@@ -47,9 +47,8 @@ class Shutdown extends Component
|
||||
public function shutdown(): void
|
||||
{
|
||||
clearstatcache(storage());
|
||||
$output = shell_exec('ls -alh /.dockerenv');
|
||||
var_dump($output);
|
||||
if (!empty($output)) {
|
||||
$output = shell_exec('[ -f /.dockerenv ] && echo yes || echo no');
|
||||
if ($output === 'yes') {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -243,8 +243,8 @@ class Snowflake
|
||||
*/
|
||||
public static function isDcoker(): bool
|
||||
{
|
||||
exec('ls -alh /.dockerenv', $output, $cod);
|
||||
if ($cod === 0 && !empty($output)) {
|
||||
exec('[ -f /.dockerenv ] && echo yes || echo no', $output, $cod);
|
||||
if ($cod === 0 && $output === 'yes') {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user