From ba3e595f78677d20a005d2a75e45e647d4763e52 Mon Sep 17 00:00:00 2001 From: f Date: Sat, 18 Mar 2023 14:31:39 -0300 Subject: [PATCH] =?UTF-8?q?fix:=20mejorar=20gesti=C3=B3n=20de=20symlink?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/deploy_www.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/models/deploy_www.rb b/app/models/deploy_www.rb index d27f77cc..bb25cc64 100644 --- a/app/models/deploy_www.rb +++ b/app/models/deploy_www.rb @@ -8,7 +8,9 @@ class DeployWww < Deploy before_destroy :remove_destination! - def deploy(**) + def deploy(output: false) + puts "Creando symlink #{site.hostname} => #{destination}" if output + File.symlink?(destination) || File.symlink(site.hostname, destination).zero? end @@ -30,7 +32,7 @@ class DeployWww < Deploy end def url - "https://www.#{site.hostname}/" + "https://#{fqdn}/" end private