Create logs, and destination directories on deploy
This commit is contained in:
parent
13234d34d1
commit
42d803e411
2 changed files with 4 additions and 0 deletions
|
@ -12,6 +12,9 @@ class Tasks::Deploy::Local
|
|||
def call
|
||||
src, dest = settings.src, settings.dest
|
||||
user, group = settings.user, settings.group
|
||||
logs_dir = settings.logs_dir
|
||||
doas "root", "/bin/mkdir", "-p", logs_dir
|
||||
doas "root", "/bin/mkdir", "-p", dest
|
||||
doas "root", "/bin/rm", "-rf", File.join(dest, "*")
|
||||
doas "root", "/bin/cp", "-r", src, dest
|
||||
doas "root", "/usr/sbin/chown", "-R", [user, group].join(":"), dest
|
||||
|
|
|
@ -25,3 +25,4 @@ deploy:
|
|||
group: www
|
||||
src: build/al-quran/.
|
||||
dest: /var/www/htdocs/al-quran.reflectslight.local/
|
||||
logs_dir: /var/www/logs/al-quran.reflectslight.local/
|
||||
|
|
Loading…
Reference in a new issue