Skip to content

Commit

Permalink
Update SetupDockerEmailServer.php
Browse files Browse the repository at this point in the history
  • Loading branch information
bobimicroweber committed Sep 17, 2024
1 parent 1eb461f commit d69d6ee
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions web/Modules/Email/App/Console/SetupDockerEmailServer.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ public function __construct()
*/
public function handle()
{

$this->info('Setting up email server...');

$workPath = '/usr/local/phyre/email/docker';
Expand All @@ -51,7 +50,7 @@ public function handle()
shell_exec('mkdir -p ' . $workPath);
file_put_contents($workPath . '/docker-compose.yaml', $dockerComposeYaml);

$ssl = DomainSslCertificate::where('domain', $domain)->first();
$ssl = DomainSslCertificate::where('domain', 'mail.'.$domain)->first();
if ($ssl) {
shell_exec('mkdir -p ' . $workPath . '/docker-data/acme-companion/certs/' . $domain);
file_put_contents($workPath . '/docker-data/acme-companion/certs/' . $domain . '/fullchain.pem', $ssl->certificate_chain);
Expand All @@ -64,9 +63,11 @@ public function handle()

// after compose you must create the email account

//docker exec -ti cc85629c8ad5 setup email add [email protected] passwd123
//docker exec -ti c2d4fec32239 setup email add [email protected] passwd123

//docker exec -ti c2d4fec32239 setup email add [email protected] passwd123

// docker exec -it cc85629c8ad5 setup config dkim
// docker exec -it c2d4fec32239 setup config dkim


//ufw allow 25
Expand Down

0 comments on commit d69d6ee

Please sign in to comment.