I’ve successfully provisioned and deployed one site with trellis. Ive managed to provision to add another site but when i deploy i get the following error:
TASK [deploy : Run npm install] ************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: OSError: [Errno 2] No such file or directory: '/Users/kristoffer/Sites/cristea/web/app/themes/webnerds'
fatal: [82.102.5.250]: FAILED! => {"changed": false, "failed": true, "parsed": false}
Ive tried to run with the -vvv flag but it gives no additional info.
webnerds is what the theme is called for my other site so it seems as if Trellis is mixing up these in some way. Any suggestions on how i might solve this?
@ben: Ah! Seems i have the settings for the old site in deploy-hooks/build-before.yml. Thank you! It looks lite this:
# Placeholder `deploy_build_before` hook for building theme assets locally
# and then copying the files to the remote server
#
# Uncomment the lines below and replace `sage` with your theme folder
#
# ---
- name: Run npm install
command: npm install
connection: local
args:
chdir: "{{ project.local_path }}/web/app/themes/webnerds"
- name: Run bower install
command: bower install
connection: local
args:
chdir: "{{ project.local_path }}/web/app/themes/webnerds"
- name: Run gulp
command: gulp --production
connection: local
args:
chdir: "{{ project.local_path }}/web/app/themes/webnerds"
- name: Copy project local files
synchronize:
src: "{{ project.local_path }}/web/app/themes/webnerds/dist"
dest: "{{ deploy_helper.new_release_path }}/web/app/themes/webnerds"
group: no
owner: no
rsync_opts: --chmod=Du=rwx,--chmod=Dg=rx,--chmod=Do=rx,--chmod=Fu=rw,--chmod=Fg=r,--chmod=Fo=r
However. Can i create different deploy hooks for different sites in group_vars/{env}/wordpress_sites.yml? Or is it better to use one Trellis clone for each site? (The sites have no relation other than that they are hosted on the same vps)