by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 12:23
    mworrell synchronize #2449
  • 12:23

    mworrell on survey-fixes-20200603

    List should be map (compare)

  • 11:57
    mworrell synchronize #2449
  • 11:57

    mworrell on survey-fixes-20200603

    More maps (compare)

  • 08:13
    mworrell synchronize #2449
  • 08:13

    mworrell on survey-fixes-20200603

    Type fixes (compare)

  • 07:30
    mworrell synchronize #2449
  • 07:30

    mworrell on survey-fixes-20200603

    Fix types. (compare)

  • Jun 03 15:21
    mworrell synchronize #2449
  • Jun 03 15:21

    mworrell on survey-fixes-20200603

    Fix z_expression (compare)

  • Jun 03 13:56
    mworrell synchronize #2449
  • Jun 03 13:56

    mworrell on survey-fixes-20200603

    More maps (compare)

  • Jun 03 12:20
    mworrell opened #2449
  • Jun 03 12:20
    mworrell milestoned #2449
  • Jun 03 12:20

    mworrell on survey-fixes-20200603

    Survey fixes for maps. (compare)

  • Jun 03 09:48
    mmzeeman closed #2448
  • Jun 03 09:48
    mmzeeman commented #2448
  • Jun 03 08:08
    mmzeeman edited #2448
  • Jun 03 08:08
    mmzeeman labeled #2448
  • Jun 03 08:08
    mmzeeman opened #2448
Marc Worrell
@mworrell
I do dev work on macOS 10.14 (Mojave), and mainly OTP 19 (also using 20) Didn't see any of these problems.
9to.one URL shortener
@9to1url_twitter
I put the Zotonic server on Centos7, local is MacOs Catalina
Maas-Maarten Zeeman
@mmzeeman
@9to1url_twitter For local development the self signed certificate should go to the "login" keychain in the category "Certificates".
Marc Worrell
@mworrell
I am wondering about the cyphers, could it be that you have an old(er) openssl version on your CentOS server? Erlang OTP uses the cyphers in openssl, maybe it is not supporting the ones that modern browsers require. Could you also check with curl? (and with the -vvv -k options)
testexplode
@testexplode
Hallo, while installing zotonic on arch I came to this problem:

=CRASH REPORT==== 1-May-2020::20:51:28.575489 ===
crasher:
initial call: mochiweb_socket_server:init/1
pid: <0.431.0>
registered_name: []
exception error: undefined function ssl_cipher_format:suite_definition/1
in function mochiweb_socket:is_secure/1 (src/mochiweb_socket.erl, line 58)
in call from lists:'-filter/2-lc$^0/1-0-'/2 (lists.erl, line 1286)
in call from mochiweb_socket:add_unbroken_ciphers_default/1 (src/mochiweb_socket.erl, line 31)
in call from mochiweb_socket:listen/4 (src/mochiweb_socket.erl, line 18)
in call from mochiweb_socket_server:listen/3 (src/mochiweb_socket_server.erl, line 218)
in call from gen_server:init_it/2 (gen_server.erl, line 374)
in call from gen_server:init_it/6 (gen_server.erl, line 342)
ancestors: [zotonic_sup,<0.300.0>]
message_queue_len: 0
messages: []
links: [<0.313.0>]
dictionary: []
trap_exit: true
status: running
heap_size: 1598
stack_size: 27
reductions: 2731
neighbours:

Terminating due to shutdown
By that i looked, if the problem is already solved by mochiweb: it is with mochiweb v2.19.0

How do i update mochiweb? I use Erlang/OTP 22 [erts-10.6.4] on Arch Linux.
Marc Worrell
@mworrell
I remember @mmzeeman also running into this issue with OTP22. Maybe we should merge some changes into the mochiweb branch we are using.
OTP21 is fine, are you stuck at 22?
(Till we can merge the changes)
testexplode
@testexplode
Well, its a hobby, not for work. But 22 is the version of Arch linux I'm using.
testexplode
@testexplode
I just saw the issue on github,. How do i install version 1.x ? Is it via just installing from the branch master ?
And is there a new mochiweb included resp. named to use?
In rebar.lock itisn't, still 2.18.
testexplode
@testexplode
The latest mochiweb 2.20.1 seems downwards compatible with the used 2.18: https://github.com/mochi/mochiweb/releases
But I'm too lazy to investigate how the rebar.lock works, from whre the packages come and how and from what the hash in rebar.lock is claculated.
Miloud Eloumri
@MiloudEloumri
Hi, Please help. I am trying to install zotonic on a live server with ip. I am using latest erlang (22.3.3) and rebar3, rebar 3.13.2. when installing zotonic and running make, I got WARN: Missing plugins: [rebar_lock_deps_plugin] in several deps and two WARN: Missing plugins: [pc]. When running bin/zotonic debug, I got crash report and errors . It looks has to do with webmachine_mochiweb_ssl, mochiweb_socket_server. Is there a way to attache txt file here in gitter? Thanks.
testexplode
@testexplode
The update to mochiweb 2.20.1 seems successful at my server:
steps are:
  1. delete or rename rebar.lock
testexplode
@testexplode
  1. in /home/zotonic/zotonic/apps/zotonic_core/rebar.config : update mochiweb to {mochiweb, "2.20.1"}
After that i can access the webpage
testexplode
@testexplode
ps: after the change a new "make" is necessary. All that happened on the master branch.
testexplode
@testexplode
Next question: A self-signed certificate is not enough for my firefox and strict security. So i wanted to use mod_ssl_ca. But the module seems not to be activated (/home/zotonic/zotonic/apps_user/my_site_name/priv/zotonic_site.config seems not being used).. instead the self-signed certificate is used, and thus I cannot reach the site. What to do ?
Marc Worrell
@mworrell
For the 0.x I will take a look on Monday. You can’t enable mod_ssl_ca on master?
You can also use letsencrypt as a ca.
On the 0.x we use a patched version of mochiweb, because of old reasons.
Miloud Eloumri
@MiloudEloumri

Hi, Please help. I am trying to install zotonic on a live server with ip. I am using latest erlang (22.3.3) and rebar3, rebar 3.13.2. when installing zotonic and running make, I got WARN: Missing plugins: [rebar_lock_deps_plugin] in several deps and two WARN: Missing plugins: [pc]. When running bin/zotonic debug, I got crash report and errors . It looks has to do with webmachine_mochiweb_ssl, mochiweb_socket_server. Is there a way to attache txt file here in gitter? Thanks.

make clean then make fixes Missing plugins: [rebar_lock_deps_plugin] in 52 deps . Missing plugins: [pc] is in /zotonic/deps/dh_date/rebar.config and /zotonic/deps/ua_classifier/rebar.config adding pc plugin according to https://github.com/zotonic/ua_classifier/blob/master/rebar.config and to https://www.rebar3.org/docs/using-available-plugins#port-compiler

Marc Worrell
@mworrell
@testexplode we update the fork of mochiweb in the 0.x, the 0.x branch should work now on OTP-22. We are still testing a bit, but this week we will release 0.57 with these fixes.
@MiloudEloumri Did you try to build after deleting the deps directory? The rebar command is a bit funny with partial updates. Our CI has successful builds for OTP19..OTP22 now (please use 0.x branch, not yet released, for OTP22).
Miloud Eloumri
@MiloudEloumri
@mworrell yes I deleted deps directory and build but still gives the same missing plugins. Adding [pc] plugin to the 2 deps I mentioned, make gives missing [pc] in another 2 deps. make clean removes missing rebar_lock_deps_plugin, but missing [pc] is still there. Is [pc] necessary? bin/zotonic debug gives a crash report mainly caused by mochiweb_socket_server, webmachine_mochiweb_ssl. Is it necessary to do zotonic config /.zotonic/0/zotonic.config editing and nginx proxy and postgresql user before running bin/zotonic debug? Thanks.
Marc Worrell
@mworrell
@MiloudEloumri The OTP22 crash in mochiweb should be fixed on the 0.x branch (which is due to become 0.57)
Our Travis-CI build works well, maybe you can just ignore the rebar messages about plugins?
Miloud Eloumri
@MiloudEloumri
@mworrell Okay. When 0.57 is planned to be released and also 1.0 ? Thanks.
Marc Worrell
@mworrell
The 0.57 will be today or coming Monday.
The 1.0 is a bit harder to plan - we will have a 1.0a in a few weeks.
For the 1.0 we are merging and fixing some changes from the 0.x and we are building a couple of production sites based on master.
Miloud Eloumri
@MiloudEloumri
Great, thanks.
Marc Worrell
@mworrell
Miloud Eloumri
@MiloudEloumri
Thanks a lot. Going to try it.
Miloud Eloumri
@MiloudEloumri
Tried Zotonic 0.57.0 and it seems working with Erlang 22. The previous missing plugins still appear when running make. make clean resolve them with remining 2 missing plugins as before, but ignoring them for now. zotonic debug did not crash and starts the server, but there is a crash report for lager_handler_watcher:init/1. Going to paste the output of bin/zotonic debug in the next post . Sorry it is long.

ubuntu@dev:~/zotonic$ bin/zotonic debug
Erlang/OTP 22 [erts-10.7.1] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1] [hipe]

Eshell V10.7.1 (abort with ^G)
(zotonic001@dev)1> ** Found 0 name clashes in code paths
=CRASH REPORT==== 12-May-2020::05:03:01.672585 ===
crasher: <<<<<<<<< A CRASH HERE
initial call: lager_handler_watcher:init/1 <<<<<<<<< A CRASH HERE
pid: <0.170.0>
registered_name: []
exception exit: noproc
in function gen:do_for_proc/2 (gen.erl, line 228)
in call from gen_event:rpc/2 (gen_event.erl, line 239)
in call from lager_handler_watcher:install_handler2/3 (src/lager_handler_watcher.erl, line 117)
in call from lager_handler_watcher:init/1 (src/lager_handler_watcher.erl, line 51)
in call from gen_server:init_it/2 (gen_server.erl, line 374)
in call from gen_server:init_it/6 (gen_server.erl, line 342)
ancestors: [lager_handler_watcher_sup,lager_sup,<0.155.0>]
message_queue_len: 0
messages: []
links: [<0.158.0>]
dictionary: []
trap_exit: false
status: running
heap_size: 610
stack_size: 27
reductions: 228
neighbours:

=INFO REPORT==== 12-May-2020::05:03:01.857656 ===
Setup running ...

=INFO REPORT==== 12-May-2020::05:03:01.859436 ===
Directories verified. Res = ok

=INFO REPORT==== 12-May-2020::05:03:01.859626 ===
Setup finished processing hooks (Mode=normal)...

=INFO REPORT==== 12-May-2020::05:03:01.888256 ===
msg: Starting reporters with []

options: []

Found 0 name clashes in code paths
=INFO REPORT==== 12-May-2020::05:03:02.180456 ===
filezcache: repopulating cache with 0 keys
=INFO REPORT==== 12-May-2020::05:03:02.180571 ===
filezcache: scanning cache directory for unknown files.
Found 0 name clashes in code paths
05:03:02.287 [info] emqtt_app:35 starting emqtt on node 'zotonic001@dev'
05:03:02.299 [info] emqtt_auth:55 emqtt_auth is started
05:03:02.300 [info] emqtt_retained:89 emqtt_retained is started.
05:03:02.301 [info] emqtt_router:121 emqtt_router is started.
05:03:02.303 [info] emqtt_registry:56 emqtt_registry is started.
05:03:02.304 [info] emqtt_client_monitor:46 emqtt_client_monitor is started.
05:03:02.307 [info] emqtt_app:38 emqtt broker is running now.
=INFO REPORT==== 12-May-2020::05:03:02.373972 ===
gen_smtp_server starting at zotonic001@dev

=INFO REPORT==== 12-May-2020::05:03:02.375592 ===
gen_smtp_server listening on {127,0,0,1}:2525 via tcp

05:03:02.409 [info] z_sites_manager:276 Site started: zotonic_status (<0.334.0>)
05:03:02.458 [info] z_filewatcher_inotify:114 [inotify] Starting inotify file monitor.
05:03:02.620 [info] z_site_startup:82 [zotonic_status] info @ z_site_startup:82 Site zotonic_status started, modules loaded
05:03:06.345 [info] zotonic_sup:171
05:03:06.345 [info] zotonic_sup:172 Zotonic started
05:03:06.345 [info] zotonic_sup:173 ===============
05:03:06.345 [info] zotonic_sup:174 Config files used:
05:03:06.345 [info] zotonic_sup:175 - /home/ubuntu/.zotonic/0/erlang.config
05:03:06.346 [info] zotonic_sup:175 - /home/ubuntu/.zotonic/0/zotonic.config
05:03:06.346 [info] zotonic_sup:176
05:03:06.346 [info] zotonic_sup:188 Web server listening on IPv4 any:8000, IPv6 ::8000, SSL :8443
05:03:06.346 [info] zotonic_sup:191

Miloud Eloumri
@MiloudEloumri
Hi, can someone help and guide me on how to run zotonic site on production.
I am using zotonic 0.57.0 with Erlang 22.3.4.
I created a zotonic site named: mas in: /home/ubuntu/zotonic/user/sites/mas.
I am using nginx 1.14.0 on Ubuntu 18.04 .
The root on the /etc/nginx/sites-avalible/default is: /var/www/html and the domain name or server name is: dev.gagnontech.org serving from /var/www/html. Also, I am using ssl from letsencrypt.
How I can proxy and server my zotonic site in such settings. For example, how to server my zotoinc site from dev.gagnontech.org/mas or directly from: dev.gagnontech.org.
I added /etc/nginx/sites-avalible/mas.test and linked it to sites-enabled and tried configs mentioned on zotonic website for proxying zotonic with nginx as is and also with some changes, but none worked for me.
I also modified zotonic.confg and erlang.config according to zotonic docs. Also added: 127.0.0.1 mas.test to /etc/hosts according to the output instructions when ran zottonic addsite mas.
Thanks a lot.
Marc Worrell
@mworrell
You need to use some proxy settings in nginx, and let nginx terminate the TLS connections.
There is some documentation here:
Note that Zotonic is running on its own ports, and is not using any of the nginx sites directories. So you don't need to add anything to the 'sites-available' or 'var/www/html' directories.
We often run zotonic from a user account called "zotonic". And keep everything in the directory of that user.