I can run it on dev mode but not in production mode.
I can't see any errors from the error log and the access log
Why dev works, not production?
boss version: 0.8.15
The last line in the console
2016-05-28 16:00:08.538 [info] <0.7.0> Application lager started on node letsparty@localhost
2016-05-28 16:00:08.554 [info] <0.59.0> Starting Boss in production mode....
2016-05-28 16:00:08.562 [info] <0.59.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.635 [info] <0.59.0> Starting master services on letsparty@localhost
2016-05-28 16:00:08.672 [info] <0.7.0> Application tinymq started on node letsparty@localhost
2016-05-28 16:00:08.715 [info] <0.59.0> SSL:[{cacertfile,"ssl/cacert.pem"},{certfile,"ssl/newcert.pem"},{keyfile,"ssl/privkey.pem"},{verify,verify_peer},{fail_if_no_peer_cert,false},{ciphers,[{rsa,aes_128_cbc,sha}]}]
2016-05-28 16:00:08.724 [info] <0.59.0> Starting cowboy... on letsparty@localhost
2016-05-28 16:00:08.733 [info] <0.7.0> Application cowlib started on node letsparty@localhost
2016-05-28 16:00:08.746 [info] <0.7.0> Application ranch started on node letsparty@localhost
2016-05-28 16:00:08.770 [info] <0.7.0> Application cowboy started on node letsparty@localhost
2016-05-28 16:00:08.770 [info] <0.59.0> Starting http listener... on 0.0.0.0:8444
2016-05-28 16:00:08.777 [notice] <0.71.0>@lager_app:132 Deprecated lager_file_backend config detected, please consider updating it
2016-05-28 16:00:08.824 [info] <0.262.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.844 [info] <0.412.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.864 [info] <0.562.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.880 [info] <0.712.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.893 [info] <0.862.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.908 [info] <0.1012.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.927 [info] <0.1162.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.944 [info] <0.1312.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.961 [info] <0.1462.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
2016-05-28 16:00:08.980 [info] <0.1612.0>@boss_db:start:77 Start Database Adapter boss_db_adapter_riaks2 options [{adapter,riaks2},{cache_enable,false},{cache_prefix,db},{shards,[]},{is_master_node,true},{db_host,"127.0.0.1"},{db_port,8087}]
It is trying to connect to riak database but it seems hanging. How can I debug this, why this works on dev mode?
I finally found the answer to problem. It's a bug I introduced. In boss template files, I extended a parent template file which later I changed its name during development, before this release.
Even so, I run init-dev.sh OK and compile to go production all right. The only log I see is that boss can't connect to database.
Finally I start to reassemble all my code piece by piece to see at what point, boss refuses me to go production. After couple of hours trying, I finally found that template file. Actually, just try to remove some files in the src/view/lib/tag_html/ if you are using them, you got the same log.
Bad experience. Why when I compile using
./rebar compileit didn't check the template file doesn't really exist.The template thing is not Erlang but more of boss thingy I guess.