|
...
|
...
|
@@ -76,7 +76,7 @@ class DomainInfo extends Command |
|
|
|
$end_day = date('Y-m-d H:i:s', strtotime('+1 month'));//域名1月后到期
|
|
|
|
$list = $domainModel->where('status', '=', 1)->get();
|
|
|
|
foreach ($list as $v) {
|
|
|
|
$project_info = $projectModel->read(['id' => $v['project_id'], 'type' => ['!=', Project::TYPE_CLOSE]], ['serve_id', 'project_type']);
|
|
|
|
$project_info = $projectModel->read(['id' => $v['project_id'], 'type' => ['!=', Project::TYPE_CLOSE]], ['serve_id', 'project_type', 'is_analysis']);
|
|
|
|
if (!$project_info) {
|
|
|
|
continue;
|
|
|
|
}
|
|
...
|
...
|
@@ -91,16 +91,18 @@ class DomainInfo extends Command |
|
|
|
$host_array = explode('.', $host);
|
|
|
|
|
|
|
|
//判断是否解析泛域名,并更改项目泛域名解析状态
|
|
|
|
$host_array_any = $host_array;
|
|
|
|
if (count($host_array_any) <= 2) {
|
|
|
|
array_unshift($host_array_any, '*');
|
|
|
|
} else {
|
|
|
|
$host_array_any[0] = '*';
|
|
|
|
}
|
|
|
|
$any_domain = implode('.', $host_array_any);
|
|
|
|
$rand_str = generateRandomString(3);
|
|
|
|
if (check_domain_record(str_replace('*', $rand_str, $any_domain), $servers_ip_info)) {
|
|
|
|
$projectModel->edit(['is_analysis' => 1], ['id' => $v['project_id']]);
|
|
|
|
if($project_info['is_analysis'] == 0){
|
|
|
|
$host_array_any = $host_array;
|
|
|
|
if (count($host_array_any) <= 2) {
|
|
|
|
array_unshift($host_array_any, '*');
|
|
|
|
} else {
|
|
|
|
$host_array_any[0] = '*';
|
|
|
|
}
|
|
|
|
$any_domain = implode('.', $host_array_any);
|
|
|
|
$rand_str = generateRandomString(3);
|
|
|
|
if (check_domain_record(str_replace('*', $rand_str, $any_domain), $servers_ip_info)) {
|
|
|
|
$projectModel->edit(['is_analysis' => 1], ['id' => $v['project_id']]);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if ($servers_ip_info['servers_id'] == ServerConfig::SELF_SITE_ID) {
|
...
|
...
|
|