Installing the Yoast SEO premium plugin via composer is very easy with Trellis.
Just add the My Yoast token to the composer authentications variable to the
# Yoast Premium account install token
No extra tasks required.
(Quite possibly) related: