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