From e6bee2ec0a8dfe2f3ed031024fab0239075be018 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Thu, 17 Feb 2022 00:18:24 +0000 Subject: [PATCH] Install a yarn wrapper to keep rails 7 happy --- cookbooks/nodejs/recipes/default.rb | 7 +++++++ cookbooks/nodejs/templates/default/yarn.erb | 3 +++ 2 files changed, 10 insertions(+) create mode 100644 cookbooks/nodejs/templates/default/yarn.erb diff --git a/cookbooks/nodejs/recipes/default.rb b/cookbooks/nodejs/recipes/default.rb index ac82c3c98..5f8ca526b 100644 --- a/cookbooks/nodejs/recipes/default.rb +++ b/cookbooks/nodejs/recipes/default.rb @@ -23,3 +23,10 @@ package %w[ g++ make ] + +template "/usr/local/bin/yarn" do + source "yarn.erb" + owner "root" + group "root" + mode "755" +end diff --git a/cookbooks/nodejs/templates/default/yarn.erb b/cookbooks/nodejs/templates/default/yarn.erb new file mode 100644 index 000000000..b9d3b4efd --- /dev/null +++ b/cookbooks/nodejs/templates/default/yarn.erb @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /usr/bin/yarnpkg --ignore-engines "$@" -- 2.39.5