Skip to content

Instantly share code, notes, and snippets.

@mustmodify
Created October 12, 2018 16:31
Show Gist options
  • Save mustmodify/84601ade245b0ff86ac0bdaf40f126aa to your computer and use it in GitHub Desktop.
Save mustmodify/84601ade245b0ff86ac0bdaf40f126aa to your computer and use it in GitHub Desktop.
demo@beaker:~/castle/releases/20181010202129/client$ sh -c "yarn run build:production"
yarn run v1.10.1
$ NODE_ENV=production webpack --config webpack.config.js
/usr/lib/node_modules/webpack-cli/bin/cli.js:244
throw err;
^
Error: Cannot find module 'webpack'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.require (module.js:497:17)
at require (/usr/lib/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
at Object.<anonymous> (/home/demo/castle/releases/20181010202129/client/webpack.config.js:5:17)
at Module._compile (/usr/lib/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:178:30)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (/usr/lib/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
at WEBPACK_OPTIONS (/usr/lib/node_modules/webpack-cli/bin/convert-argv.js:133:13)
at requireConfig (/usr/lib/node_modules/webpack-cli/bin/convert-argv.js:135:6)
at /usr/lib/node_modules/webpack-cli/bin/convert-argv.js:142:17
at Array.forEach (native)
at module.exports (/usr/lib/node_modules/webpack-cli/bin/convert-argv.js:140:15)
at yargs.parse.err (/usr/lib/node_modules/webpack-cli/bin/cli.js:241:39)
at Object.parse (/usr/lib/node_modules/webpack-cli/node_modules/yargs/yargs.js:563:18)
at /usr/lib/node_modules/webpack-cli/bin/cli.js:219:8
at Object.<anonymous> (/usr/lib/node_modules/webpack-cli/bin/cli.js:538:3)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/lib/node_modules/webpack/bin/webpack.js:155:2)
at Module._compile (module.js:570:32)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
demo@beaker:~/castle/releases/20181010202129/client$ sh -c "yarn run env"
yarn run v1.10.1
{
"NODE": "/home/demo/.nvm/versions/node/v6.9.5/bin/node",
"INIT_CWD": "/home/demo/castle/releases/20181010202129/client",
"LESSOPEN": "| /usr/bin/lesspipe %s",
"MAIL": "/var/mail/demo",
"SSH_CLIENT": "50.111.69.246 33898 22",
"USER": "demo",
"SHLVL": "1",
"RUBYOPT": "",
"OLDPWD": "/home/demo/castle/releases/20181010202129",
"HOME": "/home/demo",
"SSH_TTY": "/dev/pts/1",
"NVM_BIN": "/home/demo/.nvm/versions/node/v6.9.5/bin",
"NVM_DIR": "/home/demo/.nvm",
"LOGNAME": "demo",
"_": "/bin/sh",
"GEM_ROOT": "/opt/rubies/ruby-2.2.9/lib/ruby/gems/2.2.0",
"RUBY_VERSION": "2.2.9",
"TERM": "xterm",
"PATH": "/home/demo/castle/releases/20181010202129/client/node_modules/.bin:/home/demo/.config/yarn/link/node_modules/.bin:/home/demo/castle/releases/20181010202129/client/node_modules/.bin:/home/demo/.config/yarn/link/node_modules/.bin:/home/demo/.yarn/bin:/home/demo/.nvm/versions/node/v6.9.5/libexec/lib/node_modules/npm/bin/node-gyp-bin:/home/demo/.nvm/versions/node/v6.9.5/lib/node_modules/npm/bin/node-gyp-bin:/home/demo/.nvm/versions/node/v6.9.5/bin/node_modules/npm/bin/node-gyp-bin:/home/demo/.gem/ruby/2.2.9/bin:/opt/rubies/ruby-2.2.9/lib/ruby/gems/2.2.0/bin:/opt/rubies/ruby-2.2.9/bin:/home/demo/.nvm/versions/node/v6.9.5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games",
"RUBY_ENGINE": "ruby",
"LANG": "en_US.UTF-8",
"LS_COLORS": "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:",
"RUBY_ROOT": "/opt/rubies/ruby-2.2.9",
"SHELL": "/bin/bash",
"GEM_HOME": "/home/demo/.gem/ruby/2.2.9",
"LESSCLOSE": "/usr/bin/lesspipe %s %s",
"RAILS_ENV": "demo",
"PWD": "/home/demo/castle/releases/20181010202129/client",
"GEM_PATH": "/home/demo/.gem/ruby/2.2.9:/opt/rubies/ruby-2.2.9/lib/ruby/gems/2.2.0",
"NVM_CD_FLAGS": "",
"SSH_CONNECTION": "50.111.69.246 33898 172.31.37.61 22",
"npm_lifecycle_event": "env",
"npm_node_execpath": "/home/demo/.nvm/versions/node/v6.9.5/bin/node",
"npm_execpath": "/usr/share/yarn/bin/yarn.js",
"npm_config_argv": "{\"remain\":[],\"cooked\":[\"run\",\"env\"],\"original\":[\"run\",\"env\"]}",
"npm_package_devDependencies_react_test_renderer": "^16.5.2",
"npm_package_dependencies_webpack": "^2.3.3",
"npm_package_dependencies_redux_thunk": "^2.2.0",
"npm_package_dependencies_redux": "^3.7.2",
"npm_package_dependencies_react_sortable_hoc": "^0.8.3",
"npm_package_dependencies_react_router_dom": "^4.2.2",
"npm_package_dependencies_react_redux": "^5.0.7",
"npm_package_dependencies_react_on_rails": "6.10.1",
"npm_package_dependencies_react_leaflet": "^1.9.1",
"npm_package_dependencies_react_dom": "^15.5.4",
"npm_package_dependencies_react_datepicker": "^1.5.0",
"npm_package_dependencies_react": "^15.5.4",
"npm_package_dependencies_moment": "^2.22.1",
"npm_package_dependencies_leaflet": "^1.3.1",
"npm_package_dependencies_imports_loader": "^0.7.1",
"npm_package_dependencies_expose_loader": "^0.7.3",
"npm_package_dependencies_es5_shim": "^4.5.9",
"npm_package_dependencies_babel_runtime": "^6.23.0",
"npm_package_dependencies_babel_preset_stage_2": "^6.24.1",
"npm_package_dependencies_babel_preset_react": "^6.24.1",
"npm_package_dependencies_babel_preset_es2015": "^6.24.1",
"npm_package_dependencies_babel_polyfill": "^6.23.0",
"npm_package_dependencies_babel_loader": "^6.3.2",
"npm_package_dependencies_babel_core": "^6.24.1",
"npm_package_dependencies_babel_cli": "^6.24.1",
"npm_package_cacheDirectories_1": "client/node_modules",
"npm_package_cacheDirectories_0": "node_modules",
"npm_package_scripts_test": "jest",
"npm_package_scripts_build_development": "webpack -w --config webpack.config.js",
"npm_package_scripts_build_production": "NODE_ENV=production webpack --config webpack.config.js",
"npm_package_scripts_build_test": "webpack --config webpack.config.js",
"npm_package_private": "true",
"npm_package_version": "0.0.1",
"npm_package_name": "react-webpack-rails-tutorial",
"npm_config_version_tag_prefix": "v",
"npm_config_version_git_tag": "true",
"npm_config_version_commit_hooks": "true",
"npm_config_version_git_sign": "",
"npm_config_version_git_message": "v%s",
"npm_config_init_version": "1.0.0",
"npm_config_init_license": "MIT",
"npm_config_save_prefix": "^",
"npm_config_bin_links": "true",
"npm_config_ignore_scripts": "",
"npm_config_ignore_optional": "",
"npm_config_registry": "https://registry.yarnpkg.com",
"npm_config_strict_ssl": "true",
"npm_config_user_agent": "yarn/1.10.1 npm/? node/v6.9.5 linux x64"
}
Done in 0.10s.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment