File tree Expand file tree Collapse file tree 6 files changed +15
-5
lines changed Expand file tree Collapse file tree 6 files changed +15
-5
lines changed Original file line number Diff line number Diff line change 4
4
5
5
use App \Models \InstanceSettings ;
6
6
use App \Models \Server ;
7
+ use Illuminate \Support \Facades \File ;
8
+ use Illuminate \Support \Facades \Http ;
7
9
use Lorisleiva \Actions \Concerns \AsAction ;
8
10
9
11
class UpdateCoolify
@@ -25,6 +27,11 @@ public function handle($manual_update = false)
25
27
return ;
26
28
}
27
29
CleanupDocker::dispatch ($ this ->server , false )->onQueue ('high ' );
30
+ $ response = Http::retry (3 , 1000 )->get ('https://cdn.coollabs.io/coolify/versions.json ' );
31
+ if ($ response ->successful ()) {
32
+ $ versions = $ response ->json ();
33
+ File::put (base_path ('versions.json ' ), json_encode ($ versions , JSON_PRETTY_PRINT ));
34
+ }
28
35
$ this ->latestVersion = get_latest_version_of_coolify ();
29
36
$ this ->currentVersion = config ('version ' );
30
37
if (! $ manual_update ) {
@@ -39,6 +46,8 @@ public function handle($manual_update = false)
39
46
}
40
47
}
41
48
$ this ->update ();
49
+ $ settings ->new_version_available = false ;
50
+ $ settings ->save ();
42
51
} catch (\Throwable $ e ) {
43
52
throw $ e ;
44
53
}
Original file line number Diff line number Diff line change @@ -715,8 +715,8 @@ public function getContainers()
715
715
}
716
716
717
717
return [
718
- 'containers ' => $ containers ?? collect ([]),
719
- 'containerReplicates ' => $ containerReplicates ?? collect ([]),
718
+ 'containers ' => collect ( $ containers) ?? collect ([]),
719
+ 'containerReplicates ' => collect ( $ containerReplicates) ?? collect ([]),
720
720
];
721
721
}
722
722
Original file line number Diff line number Diff line change 1
1
<?php
2
2
3
3
use App \Actions \Proxy \SaveConfiguration ;
4
+ use App \Enums \ProxyTypes ;
4
5
use App \Models \Application ;
5
6
use App \Models \Server ;
6
7
use Symfony \Component \Yaml \Yaml ;
Original file line number Diff line number Diff line change 7
7
8
8
// The release version of your application
9
9
// Example with dynamic git hash: trim(exec('git --git-dir ' . base_path('.git') . ' log --pretty="%h" -n1 HEAD'))
10
- 'release ' => '4.0.0-beta.321 ' ,
10
+ 'release ' => '4.0.0-beta.322 ' ,
11
11
// When left empty or `null` the Laravel environment will be used
12
12
'environment ' => config ('app.env ' ),
13
13
Original file line number Diff line number Diff line change 1
1
<?php
2
2
3
- return '4.0.0-beta.321 ' ;
3
+ return '4.0.0-beta.322 ' ;
Original file line number Diff line number Diff line change 1
1
{
2
2
"coolify" : {
3
3
"v4" : {
4
- "version" : " 4.0.0-beta.321 "
4
+ "version" : " 4.0.0-beta.322 "
5
5
}
6
6
}
7
7
}
You can’t perform that action at this time.
0 commit comments