-
+
Non-root user is experimental:
docs
@@ -147,11 +147,7 @@
- No
- (create
- one
- for
- me)
+ No (create one for me)
@@ -167,18 +163,39 @@
@if (!$serverReachable)
- This server is not reachable with the following public key.
-
- Please make sure you have the correct public key in your ~/.ssh/authorized_keys file for
- user or skip the boarding process and add a new private key manually to Coolify and to the
- server.
-
- Check this documentation for further
- help.
-
- Check
- again
-
+
+
Server is not reachable
+
Please check the connection details below and correct them if they are incorrect.
+
+
+
+
+
+
+ Non-root user is experimental:
+ docs
+
+
+
+
+
+
If the connection details are correct, please ensure:
+
+ - The correct public key is in your
~/.ssh/authorized_keys
file for the specified user
+ - Or skip the boarding process and manually add a new private key to Coolify and the server
+
+
+
+
+ For more help, check this documentation.
+
+
+
+
+
+ Check again
+
+
@endif
@@ -225,27 +242,27 @@
From d378bb94bea40dd7208df12390989577bbbee0d0 Mon Sep 17 00:00:00 2001
From: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com>
Date: Tue, 10 Sep 2024 17:29:53 +0200
Subject: [PATCH 09/16] Fix: remote servers with port and user
---
app/Livewire/Boarding/Index.php | 11 ++++++-----
app/Models/Server.php | 11 ++++++-----
2 files changed, 12 insertions(+), 10 deletions(-)
diff --git a/app/Livewire/Boarding/Index.php b/app/Livewire/Boarding/Index.php
index 9503da499..514f00c3a 100644
--- a/app/Livewire/Boarding/Index.php
+++ b/app/Livewire/Boarding/Index.php
@@ -247,11 +247,12 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
public function saveServer()
{
$this->validate([
- 'remoteServerName' => 'required',
- 'remoteServerHost' => 'required',
+ 'remoteServerName' => 'required|string',
+ 'remoteServerHost' => 'required|string',
'remoteServerPort' => 'required|integer',
- 'remoteServerUser' => 'required',
+ 'remoteServerUser' => 'required|string',
]);
+
$this->privateKey = formatPrivateKey($this->privateKey);
$foundServer = Server::whereIp($this->remoteServerHost)->first();
if ($foundServer) {
@@ -379,8 +380,8 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
'name' => $this->remoteServerName,
'port' => $this->remoteServerPort,
'user' => $this->remoteServerUser,
- 'timezone' => 'UTC',
- ]);
+ 'timezone' => 'UTC',
+ ]);
$this->validateServer();
}
diff --git a/app/Models/Server.php b/app/Models/Server.php
index d30cdc9d6..46536ed47 100644
--- a/app/Models/Server.php
+++ b/app/Models/Server.php
@@ -113,8 +113,13 @@ class Server extends BaseModel
];
protected $fillable = [
+ 'name',
+ 'ip',
'port',
'user',
+ 'description',
+ 'private_key_id',
+ 'team_id',
];
protected $guarded = [];
@@ -148,11 +153,7 @@ class Server extends BaseModel
public function settings()
{
- return $this->hasOne(ServerSetting::class)->withDefault([
- 'force_disabled' => false,
- 'is_reachable' => false,
- 'is_usable' => false,
- ]);
+ return $this->hasOne(ServerSetting::class);
}
public function setupDefault404Redirect()
From 2c9491d81c684380d072f663703d6aa61126a1f7 Mon Sep 17 00:00:00 2001
From: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com>
Date: Tue, 10 Sep 2024 17:43:16 +0200
Subject: [PATCH 10/16] Fix: Do not change localhost server name on
revalidation
---
app/Livewire/Boarding/Index.php | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/Livewire/Boarding/Index.php b/app/Livewire/Boarding/Index.php
index 514f00c3a..7f913b79c 100644
--- a/app/Livewire/Boarding/Index.php
+++ b/app/Livewire/Boarding/Index.php
@@ -377,7 +377,6 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
]);
$this->createdServer->update([
- 'name' => $this->remoteServerName,
'port' => $this->remoteServerPort,
'user' => $this->remoteServerUser,
'timezone' => 'UTC',
From 826b64d056c3c7083af9600d65903d1e5efd01a0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Valentinas=20=C4=8Cirba?=
Date: Wed, 11 Sep 2024 07:57:16 +0300
Subject: [PATCH 11/16] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index c3412be14..14a741088 100644
--- a/README.md
+++ b/README.md
@@ -54,7 +54,7 @@ Special thanks to our biggest sponsors!
* [Latitude](https://latitude.sh/?ref=coolify.io) - A cloud computing platform offering bare metal servers and cloud instances for developers and businesses.
* [Brand Dev](https://brand.dev/?ref=coolify.io) - A web development agency specializing in creating custom digital experiences and brand identities.
* [Jobscollider](https://jobscollider.com/remote-jobs?ref=coolify.io) - A job search platform connecting professionals with remote work opportunities across various industries.
-* [Hostinger](https://hostinger.com?ref=coolify.io) - A web hosting provider offering affordable hosting solutions, domain registration, and website building tools.
+* [Hostinger](https://www.hostinger.com/vps/coolify-hosting?ref=coolify.io) - A web hosting provider offering affordable hosting solutions, domain registration, and website building tools.
* [Glueops](https://www.glueops.dev/?ref=coolify.io) - A DevOps consulting company providing infrastructure automation and cloud optimization services.
* [Ubicloud](https://ubicloud.com/?ref=coolify.io) - An open-source alternative to hyperscale cloud providers, offering high-performance cloud computing services.
* [Juxtdigital](https://juxtdigital.dev/?ref=coolify.io) - A digital agency offering web development, design, and digital marketing services for businesses.
From f1a1deff26b7a700614f2eadc2e97f46d043f45d Mon Sep 17 00:00:00 2001
From: Andras Bacsai
Date: Wed, 11 Sep 2024 10:21:18 +0200
Subject: [PATCH 12/16] fix: Disable mux_enabled during server validation
---
app/Livewire/Boarding/Index.php | 4 +-
.../views/livewire/boarding/index.blade.php | 338 ++++++++++--------
2 files changed, 194 insertions(+), 148 deletions(-)
diff --git a/app/Livewire/Boarding/Index.php b/app/Livewire/Boarding/Index.php
index 7f913b79c..0bfcaf729 100644
--- a/app/Livewire/Boarding/Index.php
+++ b/app/Livewire/Boarding/Index.php
@@ -282,7 +282,7 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
public function validateServer()
{
try {
- config()->set('coolify.mux_enabled', true);
+ config()->set('coolify.mux_enabled', false);
// EC2 does not have `uptime` command, lol
instant_remote_process(['ls /'], $this->createdServer, true);
@@ -296,7 +296,6 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
$this->createdServer->settings()->update([
'is_reachable' => false,
]);
-
return handleError(error: $e, livewire: $this);
}
@@ -316,6 +315,7 @@ uZx9iFkCELtxrh31QJ68AAAAEXNhaWxANzZmZjY2ZDJlMmRkAQIDBA==
$this->createdServer->settings()->update([
'is_usable' => false,
]);
+
return handleError(error: $e, livewire: $this);
}
}
diff --git a/resources/views/livewire/boarding/index.blade.php b/resources/views/livewire/boarding/index.blade.php
index c826e7b98..7b7ef8c12 100644
--- a/resources/views/livewire/boarding/index.blade.php
+++ b/resources/views/livewire/boarding/index.blade.php
@@ -1,18 +1,20 @@
@php use App\Enums\ProxyTypes; @endphp
Onboarding | Coolify
-
-
-
- @if ($currentState === 'welcome')
+
+
+
+ @if ($currentState === 'welcome')
Welcome to Coolify
Let me help you set up the basics.
- Get
+ Get
Started
- @elseif ($currentState === 'explanation')
+ @elseif ($currentState === 'explanation')
Coolify is an all-in-one application to automate tasks on your servers, deploy application with
@@ -29,21 +31,24 @@
You don't need to manage your servers anymore.
Coolify does
- it for you.
+ it for you.
+
All configurations are stored on your servers, so
- everything works without a connection to Coolify (except integrations and automations).
+ everything works without a connection to Coolify (except integrations and automations).
+
You can get notified on your favourite platforms
(Discord,
- Telegram, Email, etc.) when something goes wrong, or an action is needed from your side.
+ Telegram, Email, etc.) when something goes wrong, or an action is needed from your side.
+
- Next
+ Next
- @elseif ($currentState === 'select-server-type')
+ @elseif ($currentState === 'select-server-type')
Do you want to deploy your resources to your
@@ -52,46 +57,57 @@
?
- Localhost
+ Localhost
- Remote Server
+ Remote Server
@if (!$serverReachable)
-
-
Server is not reachable
-
Please check the connection details below and correct them if they are incorrect.
+
+
Server is not reachable
+
Please check the connection details below and correct them if they are
+ incorrect.
-
-
-
-
-
- Non-root user is experimental:
- docs
-
+
+
+
+
+
+ Non-root user is experimental:
+ docs
+
+
+
+
+
If the connection details are correct, please ensure:
+
+ - The correct public key is in your
~/.ssh/authorized_keys
+ file for the specified user
+ - Or skip the boarding process and manually add a new private key to Coolify and
+ the server
+
+
+
+
+ For more help, check this documentation.
+
+
+
+
+
+ Check Again
+
-
-
-
If the connection details are correct, please ensure:
-
- - The correct public key is in your
~/.ssh/authorized_keys
file for the specified user
- - Or skip the boarding process and manually add a new private key to Coolify and the server
-
-
-
-
- For more help, check this documentation.
-
-
-
-
-
- Check again
-
-
@endif
@@ -101,33 +117,37 @@
is the server where Coolify is running on. It is not
recommended to use one server
- for everything.
+ for everything.
+
is a server reachable through SSH. It can be hosted
at home, or from any cloud
- provider.
+ provider.
+
- @elseif ($currentState === 'private-key')
+ @elseif ($currentState === 'private-key')
Do you have your own SSH Private Key?
- Yes
+ Yes
- No (create one for me)
+ No (create one for me)
@if (count($privateKeys) > 0)
-
+
@endif
@@ -139,7 +159,7 @@
- @elseif ($currentState === 'select-existing-server')
+ @elseif ($currentState === 'select-existing-server')
There are already servers available for your Team. Do you want to use one of them?
@@ -147,15 +167,16 @@
- No (create one for me)
+ No
+ (create one for me)
@if (!$serverReachable)
-
-
Server is not reachable
-
Please check the connection details below and correct them if they are incorrect.
+
+
Server is not reachable
+
Please check the connection details below and correct them if they are
+ incorrect.
-
-
-
-
-
- Non-root user is experimental:
- docs
-
+
+
+
+
+
+ Non-root user is experimental:
+ docs
+
+
+
+
+
If the connection details are correct, please ensure:
+
+ - The correct public key is in your
~/.ssh/authorized_keys
+ file for the specified user
+ - Or skip the boarding process and manually add a new private key to Coolify and
+ the server
+
+
+
+
+ For more help, check this documentation.
+
+
+
+
+
+ Check again
+
-
-
-
If the connection details are correct, please ensure:
-
- - The correct public key is in your
~/.ssh/authorized_keys
file for the specified user
- - Or skip the boarding process and manually add a new private key to Coolify and the server
-
-
-
-
- For more help, check this documentation.
-
-
-
-
-
- Check again
-
-
@endif
@@ -206,22 +236,25 @@
- @elseif ($currentState === 'create-private-key')
+ @elseif ($currentState === 'create-private-key')
Please let me know your key details.
@@ -234,7 +267,7 @@
- @elseif ($currentState === 'create-server')
+ @elseif ($currentState === 'create-server')
Please let me know your server details.
@@ -242,33 +275,44 @@
+
From 5d476e39249be05e575e596acc4e3e6bd2be64b6 Mon Sep 17 00:00:00 2001
From: Andras Bacsai
Date: Wed, 11 Sep 2024 14:23:19 +0200
Subject: [PATCH 13/16] chore: Update server check job middleware to use server
ID instead of UUID
---
app/Jobs/ServerCheckJob.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/Jobs/ServerCheckJob.php b/app/Jobs/ServerCheckJob.php
index f7b54cd80..540085385 100644
--- a/app/Jobs/ServerCheckJob.php
+++ b/app/Jobs/ServerCheckJob.php
@@ -47,12 +47,12 @@ class ServerCheckJob implements ShouldBeEncrypted, ShouldQueue
public function middleware(): array
{
- return [(new WithoutOverlapping($this->server->uuid))];
+ return [(new WithoutOverlapping($this->server->id))];
}
public function uniqueId(): int
{
- return $this->server->uuid;
+ return $this->server->id;
}
public function handle()
From b145691e1e7a1116a8d98a3ff84a330d8ebd2b76 Mon Sep 17 00:00:00 2001
From: Andras Bacsai
Date: Wed, 11 Sep 2024 14:25:16 +0200
Subject: [PATCH 14/16] chore: Add reminder to backup .env file before running
install script again
---
scripts/install.sh | 3 +++
1 file changed, 3 insertions(+)
diff --git a/scripts/install.sh b/scripts/install.sh
index c7cfc0309..843c260a1 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -405,3 +405,6 @@ echo "Waiting for 20 seconds for Coolify to be ready..."
sleep 20
echo "Please visit http://$(curl -4s https://ifconfig.io):8000 to get started."
echo -e "\nCongratulations! Your Coolify instance is ready to use.\n"
+
+echo -e "Make sure you backup your .env file before running this script again.\n"
+echo -e "You can find it in /data/coolify/source/.env\n"
From bc13ad6b821cbd3d4ec87e1b3a361cea5dd5cd7f Mon Sep 17 00:00:00 2001
From: Andras Bacsai
Date: Wed, 11 Sep 2024 14:25:40 +0200
Subject: [PATCH 15/16] chore: Copy .env file to backup location during
installation script
---
scripts/install.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/install.sh b/scripts/install.sh
index 843c260a1..d9e570c58 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -406,5 +406,5 @@ sleep 20
echo "Please visit http://$(curl -4s https://ifconfig.io):8000 to get started."
echo -e "\nCongratulations! Your Coolify instance is ready to use.\n"
-echo -e "Make sure you backup your .env file before running this script again.\n"
-echo -e "You can find it in /data/coolify/source/.env\n"
+cp /data/coolify/source/.env /data/coolify/source/.env.backup
+echo -e "Your .env file has been copied to /data/coolify/source/.env.backup\n"
From 72f01185067201f34345ec1d21609562a0ff4e10 Mon Sep 17 00:00:00 2001
From: Andras Bacsai
Date: Wed, 11 Sep 2024 14:26:10 +0200
Subject: [PATCH 16/16] chore: Add reminder to backup .env file during
installation script
---
scripts/install.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/scripts/install.sh b/scripts/install.sh
index d9e570c58..648f78da0 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -406,5 +406,6 @@ sleep 20
echo "Please visit http://$(curl -4s https://ifconfig.io):8000 to get started."
echo -e "\nCongratulations! Your Coolify instance is ready to use.\n"
+echo -e "Make sure you backup your /data/coolify/source/.env file to a safe location, outside of this server.\n"
cp /data/coolify/source/.env /data/coolify/source/.env.backup
echo -e "Your .env file has been copied to /data/coolify/source/.env.backup\n"