Copser
Heroku deploy problem
I have a Heroku deploy problem, currently, it’s failing on installing package.json and the error is
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Phoenix app detected
remote:
remote: -----> Loading configuration and environment
remote: Loading config...
remote: WARNING: phoenix_static_buildpack.config wasn't found in the app
remote: Using default config from Phoenix static buildpack
remote: Detecting assets directory
remote: WARNING: no package.json detected in root nor custom directory
remote: * assuming phoenix 1.3.x and later, please check config file
remote: Will use phoenix configuration:
remote: * assets path assets
remote: * mix tasks namespace phx
remote: Will use the following versions:
remote: * Node 6.9.2
remote: Will export the following config vars:
remote: DATABASE_URL
remote: NODE_MODULES_CACHE
remote: POOL_SIZE
remote: SECRET_KEY_BASE
remote: * MIX_ENV=prod
remote: -----> Installing binaries
remote: Resolving node version 6.9.2...
remote: Downloading and installing node 6.9.2...
remote: Installing Node 6.9.2...
remote: Using default npm version
remote:
remote: -----> Building dependencies
remote: Installing and caching node modules
remote: npm WARN package.json @ No description
remote: npm WARN package.json @ No README data
remote: npm ERR! addLocal Could not install /tmp/build_86e0734371e98eb49ec08fbf671e37ba/deps/phoenix
remote: npm ERR! addLocal Could not install /tmp/build_86e0734371e98eb49ec08fbf671e37ba/deps/phoenix_html
remote: npm ERR! Linux 4.4.0-1057-aws
remote: npm ERR! argv "/tmp/build_86e0734371e98eb49ec08fbf671e37ba/.heroku/node/bin/node" "/tmp/build_86e0734371e98eb49ec08fbf671e37ba/.heroku/node/bin/npm" "install" "--quiet" "--unsafe-perm" "--userconfig" "/tmp/build_86e0734371e98eb49ec08fbf671e37ba/npmrc"
remote: npm ERR! node v6.9.2
remote: npm ERR! npm v3.10.9
remote: npm ERR! path /tmp/build_86e0734371e98eb49ec08fbf671e37ba/deps/phoenix
remote: npm ERR! code ENOENT
remote: npm ERR! errno -2
remote: npm ERR! syscall open
remote:
remote: npm ERR! enoent ENOENT: no such file or directory, open '/tmp/build_86e0734371e98eb49ec08fbf671e37ba/deps/phoenix'
remote: npm ERR! enoent ENOENT: no such file or directory, open '/tmp/build_86e0734371e98eb49ec08fbf671e37ba/deps/phoenix'
remote: npm ERR! enoent This is most likely not a problem with npm itself
remote: npm ERR! enoent and is related to npm not being able to find a file.
remote: npm ERR! enoent
remote:
remote: npm ERR! Please include the following file with any support request:
remote: npm ERR! /tmp/build_86e0734371e98eb49ec08fbf671e37ba/assets/npm-debug.log
remote: ! Push rejected, failed to compile Phoenix app.
I have tried https://help.heroku.com/18PI5RSY/how-do-i-clear-the-build-cache, also I have elixir-buildpack.config
elixir_version=1.8.2
erlang_version=21.2.5
assets_path=assets
phoenix_ex=phx
and phoenix_static_buildpack.config
clean_cache=true
compile="compile"
config_vars_to_export=(DATABASE_URL)
node_version=6.9.5
npm=3.10.8
phoenix_relative_path=.
remove_node=false
package.json is the default one
{
"repository": {},
"license": "MIT",
"scripts": {
"deploy": "webpack --mode production",
"watch": "webpack --mode development --watch"
},
"dependencies": {
"phoenix": "file:../deps/phoenix",
"phoenix_html": "file:../deps/phoenix_html"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"babel-loader": "^8.0.0",
"copy-webpack-plugin": "^4.5.0",
"css-loader": "^2.1.1",
"mini-css-extract-plugin": "^0.4.0",
"optimize-css-assets-webpack-plugin": "^4.0.0",
"uglifyjs-webpack-plugin": "^1.2.4",
"webpack": "4.4.0",
"webpack-cli": "^2.0.10"
}
}
but still no joy in solving the error above, did someone had something similar, how did you solved it? Thanks
Marked As Solved
Also Liked
tenzil
Hey found a similar thread in elixirforum, please check and try this
And this one as well
1
outlog
you can easily use yarn, or parcel - or whatever is the latest and greatest…
I use yarn on heroku - I just have a yarn deploy in my compile file - which of course calls the deploy script in package.json…
"scripts": {
"deploy": "NODE_ENV=production webpack --mode production",
1
Popular in Questions
In asking this question I am more interested about the expressiveness of the language itself and less concerned about the availability of...
New
Hello all!
I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New
I have followed this StackOverflow post to install the specific version of Erlang.
And When I am running mix ecto.setup then getting fol...
New
I have an umbrella app.
Some of the apps inside depend on other apps in the umbrella, unsurprisingly.
I'm writing a test for one of t...
New
I am trying to figure out how Mix knows whether the environment is test, dev, or prod -- where is this set?
Thanks.
New
Hey,
I have a NanoPi-M3 and try to install Elixir on their Ubuntu image. I followed the Raspberry Pi installation instructions from the ...
New
I have seen a lot of code which picks the first element from a list using Enum.at(0) instead of List.first. Is there a reason why people ...
New
Hey,
Just curious what are the main benefits of Elixir compared to Clojure?
When is Elixir more useful than Clojure and vice versa?
Th...
New
I’m trying to make a websocket server in Phoenix or raw Elixir. I heard about gun, I think I could use cowboy, but since I’m not that sma...
New
I am constructing a JSON object (map) and I need to conditionally set a field. I’m trying to write proper elixir-way code… and I’m at a l...
New
Other popular topics
How to handle excepions in elixir? Suppose i have A, B, C ,D, E modules. and each module has get() function. A.get() method will call th...
New
I couldn’t find any guides that worked well with Phoenix 1.6.0 and esbuild. I hope this helps people test the waters and eases you into t...
New
Hi, this is for people who, like me, have had some friction using .html.heex templates in VSCode.
The solution seems to be, in a hyphena...
New
Elixir plugin for JetBrain’s IntelliJ Platform (including Rubymine)
This is a plugin that adds support for Elixir to JetBrains IntelliJ...
New
I am trying to figure out how Mix knows whether the environment is test, dev, or prod -- where is this set?
Thanks.
New
I’m working on defining a simple Ecto schema for a table (in PostGres), but I don’t see where I can define a column as NOT NULL. Conside...
New
Hello, I have map which I want to convert it to string like this:
the map:
%{last_name: "tavakkoli", name: "shahryar"}
the string I ne...
New
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
New
Hi all,
I've just started learning Elixir and Phoenix Framework, so please pardon my n00bness at this stage.
I'm trying to use Postg...
New
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: )
Hello all, this is ...
New









