I got the couchdb image from docker (https://hub.docker.com/_/couchdb) and then i run the follow commands:
docker run -p 5984:5984 -d --name my-couchdb2 couchdb:latest
docker commit 1d329ef7c516 registry.heroku.com/coucherte/web
docker tag my-couchdb2 registry.heroku.com/coucherte/web
docker push registry.heroku.com/coucherte/web
heroku container:release web --app coucherte
After this the dyno crashes, with "heroku logs --app coucherte" i get this log:
2019-02-28T17:55:15.064991+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=coucherte.herokuapp.com request_id=b875a9ce-6b45-4e37-b0fa-9a0ff243b5de fwd="177.251.168.219" dyno= connect= service= status=503 bytes= protocol=http
2019-02-28T17:55:15.542527+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=coucherte.herokuapp.com request_id=291c7afd-0e7d-41f2-846e-6555dbdb4621 fwd="177.251.168.219" dyno= connect= service= status=503 bytes= protocol=http
2019-02-28T18:00:23.647796+00:00 heroku[web.1]: State changed from crashed to starting
2019-02-28T18:00:27.580280+00:00 heroku[web.1]: Starting process with command `/opt/couchdb/bin/couchdb`
2019-02-28T18:00:28.727119+00:00 heroku[web.1]: State changed from starting to crashed
2019-02-28T18:00:28.670713+00:00 app[web.1]: [WARN tini (4)] Tini is not running as PID 1 and isn't registered as a child subreaper.
2019-02-28T18:00:28.670738+00:00 app[web.1]: Zombie processes will not be re-parented to Tini, so zombie reaping won't work.
2019-02-28T18:00:28.670753+00:00 app[web.1]: To fix the problem, use the -s option or set the environment variable TINI_SUBREAPER to register Tini as a child subreaper, or run Tini as PID 1.
2019-02-28T18:00:28.674975+00:00 app[web.1]: find: 'couchdb' is not the name of a known user
2019-02-28T18:00:28.727539+00:00 heroku[web.1]: Process exited with status 1
2019-02-28T18:02:42.410954+00:00 heroku[web.1]: State changed from crashed to starting
2019-02-28T18:02:51.032603+00:00 heroku[web.1]: Starting process with command `/opt/couchdb/bin/couchdb`
2019-02-28T18:02:53.540759+00:00 heroku[web.1]: State changed from starting to crashed
2019-02-28T18:02:53.517057+00:00 heroku[web.1]: Process exited with status 1
2019-02-28T18:02:53.453924+00:00 app[web.1]: [WARN tini (4)] Tini is not running as PID 1 and isn't registered as a child subreaper.
2019-02-28T18:02:53.453944+00:00 app[web.1]: Zombie processes will not be re-parented to Tini, so zombie reaping won't work.
2019-02-28T18:02:53.453960+00:00 app[web.1]: To fix the problem, use the -s option or set the environment variable TINI_SUBREAPER to register Tini as a child subreaper, or run Tini as PID 1.
2019-02-28T18:02:53.454218+00:00 app[web.1]: find: 'couchdb' is not the name of a known user
What i am doing wrong? How i have to change the PORT for Heroku? Do i have to change couchdb settings to work with HTTPS when working with Heroku?
UPDATE
I now figured out that inside the image in the root directory there is a file called docker-entrypoint.sh. In this file there is this line:
find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f couchdb:couchdb '{}' +
So on this line i think it crashes in heroku. So there is a problem with the user couchdb. Localy it works and i can find the user with:
cut -d: -f1 /etc/passwd
but on heroku the user does not exist or cannot be found. Why?
UPDATE 2
The answer is here: https://github.com/apache/couchdb-docker/issues/136
Related
I am trying to deploy an app https://github.com/valasek/timesheet on Heroku using a docker image.
App has a go backend (negroni/gorilla) and Vue.js/Vuetify.js on the frontend and is using PostgreSQL persistence.
I am stuck on deployment. I do not know how to debug, how to show the command line output, what is failing ... and any help highly appreciated.
Relevant Dockerfile - https://github.com/valasek/timesheet/blob/master/Dockerfile
Here are the steps I am doing:
> docker build --rm -f "Dockerfile" -t timesheet:latest .
Successfully tagged timesheet:latest
...
> heroku container:push timesheet:latest --app timesheet-cloud
...
The push refers to repository [registry.heroku.com/timesheet-cloud/timesheet]
...
Your image has been successfully pushed. You can now release it with the 'container:release' command.
> heroku container:release timesheet --app timesheet-cloud
Releasing images timesheet to timesheet-cloud... done
> heroku ps -a timesheet-cloud
Free dyno hours quota remaining this month: 971h 8m (97%)
Free dyno usage for this app: 0h 0m (0%)
For more information on dyno sleeping and how to upgrade, see:
https://devcenter.heroku.com/articles/dyno-sleeping
No dynos on ⬢ timesheet-cloud
> heroku logs --app timesheet-cloud
2019-02-15T08:33:49.373221+00:00 app[api]: Deployed timesheet (709022e100f9) by user <email-reducted>#gmail.com
2019-02-15T08:33:49.373221+00:00 app[api]: Release v20 created by user <email-reducted>#gmail.com
2019-02-15T08:34:43.901070+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/" host=timesheet-cloud.herokuapp.com request_id=4c21eb79-5344-4d40-b341-8977128c873f fwd="195.250.152.42" dyno= connect= service= status=503 bytes= protocol=https
2019-02-15T08:34:44.842322+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/favicon.ico" host=timesheet-cloud.herokuapp.com request_id=b66caaee-880a-46a0-918b-e778a49334f4 fwd="195.250.152.42" dyno= connect= service= status=503 bytes= protocol=https
2019-02-15T08:34:54.865321+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/" host=timesheet-cloud.herokuapp.com request_id=d5af6aa7-0279-4f0e-a4cc-0f9e8682ec2f fwd="195.250.152.42" dyno= connect= service= status=503 bytes= protocol=https
2019-02-15T08:34:55.158317+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/favicon.ico" host=timesheet-cloud.herokuapp.com request_id=2d69f4b5-9015-48de-9314-c493703818d1 fwd="195.250.152.42" dyno= connect= service= status=503 bytes= protocol=https
This is likely to happen because Heroku does not detect any endpoint for your application (binded on port 3000 by default).
Heroku attributes your app a dynamic port, and put the port value on the env variable named $PORT.
Your app have to use the value specified by Heroku in this variable and listen for incoming connections on it, because that is where Heroku will forward connections.
The variable has to be read when the app starts:
https://help.heroku.com/PPBPA231/how-do-i-use-the-port-environment-variable-in-container-based-apps
You can check current env variables on your app using heroku run printenv
(I see you are using Viper, that should handle env variables. However they say in their documentation that when from env, it is case sensitive, maybe that could explain why it does not work for you: https://github.com/spf13/viper#working-with-environment-variables)
Thank you #Jonathan Muller. Solved!
GUI is running on https://timesheet-cloud.herokuapp.com.
On Heroku DB connection and PORT string should be read from the environment variables
DATABASE_URL
PORT
Updated was file timesheet.yaml.
BaseUrl in Axios is set to '' so Axios is using relative API URLs, which works. Fixed in file axiosSettings.js.
Before the command heroku run printenv returned:
panic: dial tcp 127.0.0.1:5432: connect: connection refused
Now I am getting:
Running printenv on ⬢ timesheet-cloud... up, run.1962 (Free)
Feb 15 16:22:34.186 [INFO] config file /timesheet.yaml
Feb 15 16:22:34.197 [INFO] connecting to DB postgres://user:hash#ec2-54-235-68-3.compute-1.amazonaws.com:5432/dbname
Feb 15 16:22:34.246 [INFO] connected to DB postgres://user:hash#ec2-54-235-68-3.compute-1.amazonaws.com:5432/dbname
Below is the Docker file:
FROM tomcat:7.0.90-jre7-alpine
ENV spring.profiles.active=dev
ENV CATALINA_OPTS=" -Dlogback.ContextSelector=JNDI"
#ADD builds/lib/ILCH-*.war $CATALINA_HOME/webapps/ilch.war
ADD heroku/catalina.sh /usr/local/tomcat/bin
RUN `chmod 777 /usr/local/tomcat/bin/catalina.sh`
Tomcat Server is started successfully per the below logs after container released:
heroku container:release web --app runningticker
The port assignment is good as I updated the server.xml inside the Catalina.sh before starting the server. (Last but one line in the docker file)
The requests to this application are not serving and I always see the logs code=H80 desc="Maintenance mode"
2018-09-22T19:38:08.446927+00:00 app[web.1]: INFO: Server startup in 5965 ms
2018-09-22T19:39:05.242821+00:00 heroku[router]: at=info code=H80 desc="Maintenance mode" method=GET path="/"
host=runningticker.herokuapp.com
request_id=e1cb4819-6bd9-4b04-8fc5-09c1bb2d7ad1 fwd="72.48.50.103"
dyno= connect= service= status=503 bytes= protocol=https
Expected to run the ROOT application of tomcat home page, but not.
What am I missing? Port binding while docker run? If so, how can I do this on Heroku?
If you wonder what's there in Catalina.sh this is the first line I added.
sed -i -e "s/8080/$PORT/" /usr/local/tomcat/conf/server.xml
I am trying to deploy my minio server to heroku. This is my Dockerfile:
FROM minio/minio
ENV MINIO_ACCESS_KEY="xxxxxx"
ENV MINIO_SECRET_KEY="xxxxxxxx"
CMD ["server", "/data"]
EXPOSE 9000
This works locally when I build and run it through docker (using these commands:)
docker build . -t testheroku
sudo docker run -p 8080:8080 testheroku
The Dockerfile is the only file in the directory.
Then, I try to push it to heroku. I followed the commands on the heroku docker instruction page to install the heroku container plugin, login, etc. Then, I pushed my app with: heroku container:push web --app APP_NAME
When I visit the app, I get an application error in browser. This is what the heroku logs display:
2017-09-21T02:24:47.589576+00:00 app[api]: Deployed web (26b84915ed48) by user []
2017-09-21T02:24:47.589576+00:00 app[api]: Release v28 created by user []
2017-09-21T02:24:48.241050+00:00 heroku[web.1]: State changed from crashed to starting
2017-09-21T02:24:49.480733+00:00 heroku[web.1]: Starting process with command `server /data`
2017-09-21T02:24:51.961825+00:00 app[web.1]: ‘server /data’ is not a minio sub-command. See ‘minio --help’.
2017-09-21T02:24:52.056706+00:00 heroku[web.1]: Process exited with status 1
2017-09-21T02:24:52.064400+00:00 heroku[web.1]: State changed from starting to crashed
2017-09-21T02:24:52.938136+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=APP_NAME.herokuapp.com request_id=80ddd6f8-c053-4ff6-b4c9-fdb0ce8a48a5 fwd="67.245.14.153" dyno= connect= service= status=503 bytes= protocol=https
2017-09-21T02:24:54.319660+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=APP_NAME.herokuapp.com request_id=9988b6af-8a91-4e77-9bd4-c79c9e2ec24c fwd="67.245.14.153" dyno= connect= service= status=503 bytes= protocol=https
For those unfamiliar with minio, some explanation of ‘server /data’ is not a minio sub-command. See ‘minio --help’.: this shows when you run the minio command with an argument that isn't a minio command. For example,
./minio sadf
‘sadf’ is not a minio sub-command. See ‘minio --help’.
So what heroku is telling me is that it's interpreting the CMD line from my Dockerfile, not as it should (which is with server as the minio subcommand and /data as its argument) but instead, if you notice the quotation marks, heroku is smashing the two pieces together and attempting to use the whole string as a minio subcommand - hence the error message. It's trying to run the command minio 'server /data' instead of minio server /data
Has anyone seen this kind of behavior from heroku before with a Dockerfile? How can I make sure that the CMD line gets interpreted correctly, and not as one full string? I assume this is a heroku issue because it runs fine locally. Any advice would be welcome.
I had a similar issue that seemed to be caused by having other ENTRYPOINTS in the parent layers. To solve this, I added ENTRYPOINT [] above my CMD and everything worked fine.
Actually, I had the same issue.
This Dockerfile works fine.
FROM minio/minio:RELEASE.2022-01-08T03-11-54Z.fips
ENV MINIO_ROOT_USER=XXXXXX
ENV MINIO_ROOT_PASSWORD=XXXXXX
EXPOSE 9000
EXPOSE 9001
ENTRYPOINT ["minio"]
CMD ["server","/data","--console-address",":9001"]
I'm deploying a Rails (Rails v5.0.0.1) app to heroku. However when I try visiting the app it crashes with error code of H10. After googling for a while I tried restarting all dynos for the app as people suggest but it didn't work. What's even weirder is that I cannot run heroku run rails console to access the console, when I run that, it shows:
Usage:
rails new APP_PATH [options]
Options:
-r, [--ruby=PATH] # Path to the Ruby binary of your choice
# Default: /app/vendor/ruby-2.3.0/bin/ruby
-m, [--template=TEMPLATE] # Path to some application template (can be a filesystem path or URL)
-d, [--database=DATABASE] # Preconfigure for selected database (options: mysql/oracle/postgresql/sqlite3/frontbase/ibm_db/sqlserver/jdbcmysql/jdbcsqlite3/jdbcpostgresql/jdbc)
# Default: sqlite3
-j, [--javascript=JAVASCRIPT] # Preconfigure for selected JavaScript library
# Default: jquery
[--skip-gemfile], [--no-skip-gemfile] # Don't create a Gemfile
-B, [--skip-bundle], [--no-skip-bundle] # Don't run bundle install
-G, [--skip-git], [--no-skip-git] # Skip .gitignore file
[--skip-keeps], [--no-skip-keeps] # Skip source control .keep files
-M, [--skip-action-mailer], [--no-skip-action-mailer] # Skip Action Mailer files
-O, [--skip-active-record], [--no-skip-active-record] # Skip Active Record files...
Note that I can run heroku run rake db:migrate after pushing to heroku. Here's the logs:
2016-12-18T06:44:34.515479+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T06:44:46.337848+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=fd929087-20a6-4c20-b534-f14261d3de11 fwd="210.245.33.22" dyno= connect= service= status=503 bytes=
2016-12-18T06:44:46.757726+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=ff3d39de-e593-41d4-b8d1-26fa9befc27e fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T06:46:59.953430+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T06:47:05.203056+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 26350 -e production`
2016-12-18T06:47:06.697360+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T06:47:06.797834+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T06:47:06.798798+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T06:47:06.775021+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T06:47:11.275436+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 31405 -e production`
2016-12-18T06:47:13.273106+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T06:47:13.382651+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T06:47:13.364125+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T06:47:15.177482+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=838f042a-36fb-4b80-9dd1-68146388a2f9 fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T06:47:14.847769+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=329ddb98-3588-4a7e-ba85-86f2ebb0c787 fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T06:47:17.892965+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=64f4d85b-f4be-473b-886b-16bcbabcebb2 fwd="210.245.33.22" dyno= connect= service= status=503 bytes=
2016-12-18T06:47:18.158159+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=6f95c551-e2a1-4afd-aa6a-00344743d3d9 fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T06:47:35.998915+00:00 app[api]: Starting process with command `bundle exec rake rails console` by user yaphats280396#gmail.com
2016-12-18T06:47:42.534769+00:00 heroku[run.1014]: Awaiting client
2016-12-18T06:47:42.584498+00:00 heroku[run.1014]: Starting process with command `bundle exec rake rails console`
2016-12-18T06:47:42.560559+00:00 heroku[run.1014]: State changed from starting to up
2016-12-18T06:47:50.393316+00:00 heroku[run.1014]: Process exited with status 1
2016-12-18T06:47:50.411848+00:00 heroku[run.1014]: State changed from up to complete
2016-12-18T06:48:03.813169+00:00 app[api]: Starting process with command `rails console` by user yaphats280396#gmail.com
2016-12-18T06:48:09.475386+00:00 heroku[run.8367]: Awaiting client
2016-12-18T06:48:09.520745+00:00 heroku[run.8367]: Starting process with command `rails console`
2016-12-18T06:48:09.640673+00:00 heroku[run.8367]: State changed from starting to up
2016-12-18T06:48:14.736012+00:00 heroku[run.8367]: State changed from up to complete
2016-12-18T06:48:14.699247+00:00 heroku[run.8367]: Process exited with status 0
2016-12-18T06:52:47.096470+00:00 heroku[slug-compiler]: Slug compilation started
2016-12-18T06:55:24.601041+00:00 heroku[slug-compiler]: Slug compilation started
2016-12-18T06:58:02.189014+00:00 app[api]: Deploy 18728fe by user yaphats280396#gmail.com
2016-12-18T06:58:02.189014+00:00 app[api]: Release v6 created by user yaphats280396#gmail.com
2016-12-18T06:58:02.340404+00:00 heroku[slug-compiler]: Slug compilation started
2016-12-18T06:58:02.340411+00:00 heroku[slug-compiler]: Slug compilation finished
2016-12-18T06:58:02.437765+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T06:58:07.513403+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 44886 -e production`
2016-12-18T06:58:09.081681+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T06:58:08.964854+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T06:58:09.105664+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T07:00:25.355827+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T07:00:30.147971+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 52383 -e production`
2016-12-18T07:00:31.821352+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T07:00:31.890663+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T07:00:31.872039+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T07:01:45.326964+00:00 app[api]: Starting process with command `bundle exec rake db:migrate` by user yaphats280396#gmail.com
2016-12-18T07:01:50.459013+00:00 heroku[run.9961]: Awaiting client
2016-12-18T07:01:50.478532+00:00 heroku[run.9961]: Starting process with command `bundle exec rake db:migrate`
2016-12-18T07:01:50.751333+00:00 heroku[run.9961]: State changed from starting to up
2016-12-18T07:01:56.569373+00:00 heroku[run.9961]: Process exited with status 0
2016-12-18T07:01:56.582918+00:00 heroku[run.9961]: State changed from up to complete
2016-12-18T07:02:03.799642+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=a886d9c7-771c-4bbc-b0ae-c69a9a2711eb fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T07:02:04.128488+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=b639d3fe-89b8-4e85-bec5-092711ab9177 fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T07:02:06.282079+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=2a99589c-6000-464f-8d6e-15bca538bb84 fwd="210.245.33.22" dyno= connect= service= status=503 bytes=
2016-12-18T07:02:06.575156+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=b520a6ee-4bfa-4116-b535-ce00c641097c fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T07:02:23.077596+00:00 app[api]: Starting process with command `rails console` by user yaphats280396#gmail.com
2016-12-18T07:02:29.656336+00:00 heroku[run.4122]: Awaiting client
2016-12-18T07:02:29.734024+00:00 heroku[run.4122]: Starting process with command `rails console`
2016-12-18T07:02:29.759224+00:00 heroku[run.4122]: State changed from starting to up
2016-12-18T07:02:35.660219+00:00 heroku[run.4122]: State changed from up to complete
2016-12-18T07:02:35.644039+00:00 heroku[run.4122]: Process exited with status 0
2016-12-18T07:06:57.871793+00:00 app[api]: Starting process with command `rails console` by user yaphats280396#gmail.com
2016-12-18T07:07:04.028124+00:00 heroku[run.5253]: State changed from starting to up
2016-12-18T07:07:04.151355+00:00 heroku[run.5253]: Awaiting client
2016-12-18T07:07:04.186644+00:00 heroku[run.5253]: Starting process with command `rails console`
2016-12-18T07:07:09.461403+00:00 heroku[run.5253]: Process exited with status 0
2016-12-18T07:07:09.459229+00:00 heroku[run.5253]: State changed from up to complete
2016-12-18T07:08:01.251294+00:00 app[api]: Starting process with command `spring stop` by user yaphats280396#gmail.com
2016-12-18T07:08:06.994287+00:00 heroku[run.2057]: Awaiting client
2016-12-18T07:08:07.013915+00:00 heroku[run.2057]: Starting process with command `spring stop`
2016-12-18T07:08:07.238356+00:00 heroku[run.2057]: State changed from starting to up
2016-12-18T07:08:11.161840+00:00 heroku[run.2057]: State changed from up to complete
2016-12-18T07:08:11.142680+00:00 heroku[run.2057]: Process exited with status 1
2016-12-18T07:18:42.513123+00:00 heroku[slug-compiler]: Slug compilation started
2016-12-18T07:18:42.513132+00:00 heroku[slug-compiler]: Slug compilation finished
2016-12-18T07:18:42.641136+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T07:18:42.376404+00:00 app[api]: Release v7 created by user yaphats280396#gmail.com
2016-12-18T07:18:42.376404+00:00 app[api]: Deploy 0f0c253 by user yaphats280396#gmail.com
2016-12-18T07:18:48.864292+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 56507 -e production`
2016-12-18T07:18:51.479943+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T07:18:51.513045+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T07:18:51.514288+00:00 heroku[web.1]: State changed from crashed to starting
2016-12-18T07:18:51.351956+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T07:18:56.601461+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 47201 -e production`
2016-12-18T07:18:58.427067+00:00 app[web.1]: bash: bin/rails: No such file or directory
2016-12-18T07:18:58.490908+00:00 heroku[web.1]: Process exited with status 127
2016-12-18T07:18:58.523092+00:00 heroku[web.1]: State changed from starting to crashed
2016-12-18T07:19:26.047830+00:00 app[api]: Starting process with command `bundle exec rake db:migrate` by user yaphats280396#gmail.com
2016-12-18T07:19:31.378985+00:00 heroku[run.4257]: Awaiting client
2016-12-18T07:19:31.407367+00:00 heroku[run.4257]: Starting process with command `bundle exec rake db:migrate`
2016-12-18T07:19:31.663915+00:00 heroku[run.4257]: State changed from starting to up
2016-12-18T07:19:37.609181+00:00 heroku[run.4257]: State changed from up to complete
2016-12-18T07:19:37.628694+00:00 heroku[run.4257]: Process exited with status 0
2016-12-18T07:19:47.465402+00:00 app[api]: Starting process with command `rails console` by user yaphats280396#gmail.com
2016-12-18T07:19:53.296424+00:00 heroku[run.8574]: Awaiting client
2016-12-18T07:19:53.460124+00:00 heroku[run.8574]: State changed from starting to up
2016-12-18T07:19:53.343683+00:00 heroku[run.8574]: Starting process with command `rails console`
2016-12-18T07:19:57.742878+00:00 heroku[run.8574]: State changed from up to complete
2016-12-18T07:19:57.727626+00:00 heroku[run.8574]: Process exited with status 0
2016-12-18T07:20:40.222378+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=mighty-island-98480.herokuapp.com request_id=221c14dd-1775-4891-83ce-e8a24678075f fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
2016-12-18T07:20:40.532629+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=mighty-island-98480.herokuapp.com request_id=5b2ff337-7233-49bc-a4a8-6b8dd1d485ff fwd="203.205.28.130" dyno= connect= service= status=503 bytes=
I've deployed a couple of apps to Heroku before but never come across this weird situation. I will provide further files/details if needed.
I figured it out: I forgot to provide a Procfile for Puma
I just deployed my app on heroku. Then I ran:
heroku ps:scale web=1
Which ran ok, but when I wanted to check the dyno working with heroku ps I got the following:
=== web (1X): `bin/rails server -p $PORT -e $RAILS_ENV`
web.1: crashed 2015/01/19 11:18:38 (~ 3m ago)
heroku logs:
2015-01-19T15:14:06.131511+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/favicon.ico"
host=rock-paper-scissors-test.herokuapp.com
request_id=27ca44cb-ca4e-473e-9789-0245d393bd56
fwd="190.15.209.212" dyno= connect= service= status=503 bytes=
Any ideas?
UPDATE:
get the following line before exiting on heroku logs:
2015-01-19T15:28:57.189329+00:00 app[web.1]: => Notice: server is listening on all interfaces (0.0.0.0). Consider using 127.0.0.1 (--binding option)
2015-01-19T15:28:57.922629+00:00 heroku[web.1]: Process exited with status 1
Try the suggestion you're receiving in the logs:
Consider using 127.0.0.1 (--binding option)
Change your Procfile to:
bin/rails server -p $PORT -e $RAILS_ENV --binding 127.0.0.1
There was an error that wasn't being addressed in the logs. I had to run:
heroku run console
to get the details. Just like they advice here.