Hi.
WPMU Smush Pro create folder with WebP images on: site/webp/app/smush-webp/
Could I ask for a help to get trellis copy this directory to /shared/ as it’s doing with uploads dir? <- And reverse, get it into place on deploy finish
As each deploy delete this folder and need to run Smush for WebP again.
I believe what you’re looking for is project_shared_children
.
Take a look at this file in Trellis:
- vendor
# All the templates to process on the remote system on deploy. These could contain config files.
# `src` and `dest` paths work the same as project_local_files.
project_templates:
- name: .env config
src: roles/deploy/templates/env.j2
dest: .env
mode: '0600'
# The shared_children is a list of all files/folders in your project that need to be linked to a path in `/shared`.
# For example a sessions directory or an uploads folder. They are created if they don't exist, with the type
# specified in the `type` key (file or directory).
# Example:
# project_shared_children:
# - path: app/sessions
# src: sessions
# mode: '0755' // <- optional, use an octal number starting with 0 or quote it, defaults to `'0755'` if `directory` or `'0644'` if `file`
# type: directory // <- optional, defaults to `directory`, options: `directory` or `file`
project_shared_children:
- path: web/app/uploads
MWDelaney:
project_shared_children
Looks exactly what I needed, thank you!
system
Closed
July 7, 2021, 2:03pm
4
This topic was automatically closed after 42 days. New replies are no longer allowed.