Skip to content

Commit

Permalink
Install yarn in the supermarket def
Browse files Browse the repository at this point in the history
Also remove sprockets from the gemfile now that it's built into rails.

Signed-off-by: Tim Smith <[email protected]>
  • Loading branch information
tas50 committed Jul 29, 2021
1 parent 362ddd3 commit 0a1b43a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
5 changes: 4 additions & 1 deletion omnibus/config/software/supermarket.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
dependency "chef-gem"
dependency "git"
dependency "nginx"
dependency "nodejs"
dependency "nodejs-binary"
dependency "postgresql"
dependency "redis"
dependency "ruby"
Expand All @@ -35,6 +35,7 @@

build do
env = with_standard_compiler_flags(with_embedded_path)
env['PATH'] = "#{env['PATH']}:#{install_dir}/embedded/nodejs/bin"

bundle "package --all --no-install"

Expand All @@ -45,6 +46,8 @@
" --without development doc",
env: env

command "npm install yarn -g", env: env

# This fails because we're installing Ruby C extensions in the wrong place!
bundle "exec rake assets:precompile", env: env.merge('RAILS_ENV' => 'production')

Expand Down
3 changes: 3 additions & 0 deletions omnibus/cookbooks/omnibus-supermarket/Gemfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
source "https://rubygems.org"

# This gemfile is currently used in the omnibus build for the -ctl command
# Why is it here? Great question. This needs to get refactored away with the
# ctl command have its own gemspec.
Expand All @@ -10,4 +12,5 @@ gem 'inspec-bin'
# including this group here
group :test do
gem 'chefspec'
gem 'chef', '< 17'
end
4 changes: 0 additions & 4 deletions src/supermarket/Gemfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
source "https://rubygems.org"

# Ruby version isn't specified here anymore, as it's pinned in Omnibus
# https://github.com/chef/omnibus-supermarket/blob/master/config/projects/supermarket.rb

gem "fieri", path: "engines/fieri"
gem "rails", "~> 5.2.6"

Expand Down Expand Up @@ -45,7 +42,6 @@ gem "sass-globbing"
gem "sass-rails"
gem "sentry-raven", require: false
gem "sitemap_generator"
gem "sprockets"
gem "statsd-ruby"
gem "tomlrb"
gem "uglifier"
Expand Down
1 change: 0 additions & 1 deletion src/supermarket/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,6 @@ DEPENDENCIES
sitemap_generator
spring
spring-commands-rspec
sprockets
statsd-ruby
tomlrb
uglifier
Expand Down

0 comments on commit 0a1b43a

Please sign in to comment.