File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -198,13 +198,17 @@ public function isMuslLinux(): bool {
198198 }
199199
200200 public function getOsArch (): string {
201+ $ arm64_names = array ("aarch64 " , "armv8 " , "arm64 " );
201202 $ machineType = php_uname ('m ' );
202203 if (str_contains ($ machineType , 'x86_64 ' )) {
203204 return 'amd64 ' ;
204- } elseif (str_contains ($ machineType , 'arm64 ' )) { // @codeCoverageIgnoreStart
205- return 'arm64 ' ;
206205 }
207- return $ machineType ; // @codeCoverageIgnoreEnd
206+ foreach ($ arm64_names as $ arm64_name ) {
207+ if (str_contains ($ machineType , $ arm64_name )) {
208+ return 'arm64 ' ;
209+ }
210+ }
211+ return $ machineType ; // probably we should log here value or raise an exception
208212 }
209213
210214 public function getCustomAppsDirectory (): string {
You can’t perform that action at this time.
0 commit comments