Https://github.com/penpot/penpot/discussions/2105

Hello team.

I came to realise just now that all questions and discussions are supposed to be moved here. Can someone please tell me what i am missing ? Here is the discussion i started on github.

starting penpot from latest releases

1 Like

Hello!,

After the run-devenv command is executed you should have access to a tmux with four tabs. Could you please check what’s happening inside those four tabs?

They seem to all be running with no errors. I noticed there is a step for creating an initial profile[1] but that is not documented for the dev environment. Perhaps that is the issue ?

How do i run create-profile from the dev environment in one of the tmux ?

docker exec -ti penpot-penpot-backend-1 ./manage.sh create-profile

[1] 1. Getting Started

It shouldn’t be related to that…

That manage.sh isn’t exposed directly for devenv (in devenv you can register users by default)

Could you please attach screenshots from the different tabs?, where are you executing the curl from?

You can also attach to the running docker with something like “docker exec -ti penpot-devenv-main /bin/bash” and from there launch something like “tail -f /var/log/nginx/error.log” to see if there is more info about the nginx error

Here is the tmux backend log

tab3-backend

penpot@978be0c51c7c:~/penpot/backend$ ./scripts/start-dev
+ '[' '' = --watch ']'
+ clojure -A:dev -M -m app.main
Reflection warning, user.clj:84:22 - call to static method alength on clojure.lang.RT can't be resolved (argument types: unknown).
Reflection warning, user.clj:85:22 - call to static method alength on clojure.lang.RT can't be resolved (argument types: unknown).
Reflection warning, user.clj:86:22 - call to static method alength on clojure.lang.RT can't be resolved (argument types: unknown).
Reflection warning, user.clj:87:22 - call to static method alength on clojure.lang.RT can't be resolved (argument types: unknown).
Reflection warning, app/worker.clj:130:29 - reference to field isShutdown on java.lang.Object can't be resolved.
Reflection warning, app/worker.clj:177:5 - reference to field getSQLState can't be resolved.
Reflection warning, app/worker.clj:177:5 - reference to field getSQLState can't be resolved.
Reflection warning, app/msgbus.clj:117:19 - call to static method create on io.lettuce.core.RedisURI can't be resolved (argument types: java.lang.Object).
[2022-07-26 13:14:21.065] I app.metrics - action="initialize metrics"
[2022-07-26 13:14:21.068] I app.db - hint="initialize connection pool", name="main", uri="postgresql://postgres/penpot", read-only=false, with-credentials=true, min-size=0, max-size=30
[2022-07-26 13:14:21.224] I app.loggers.audit - hint="audit log collector initialized"
[2022-07-26 13:14:21.225] I app.msgbus - hint="initialize msgbus", buffer-size=128, redis-uri="redis://redis/0"
[2022-07-26 13:14:21.655] D app.http.session - hint="initializing session gc task", max-age=#app/duration "360h"
[2022-07-26 13:14:21.664] I app.http.session - action="initialize session updater", max-batch-age="PT5M", max-batch-size="200"
[2022-07-26 13:14:21.717] I app.http - hint="starting http server", port=6060, host="0.0.0.0", name="http"
[2022-07-26 13:14:21.726] I io.undertow - starting server: Undertow - 2.2.17.Final
[2022-07-26 13:14:21.730] I org.xnio - XNIO version 3.8.6.Final
[2022-07-26 13:14:21.732] I org.xnio.nio - XNIO NIO Implementation Version 3.8.6.Final
[2022-07-26 13:14:21.742] I org.jboss.threads - JBoss Threads version 3.1.0.Final
[2022-07-26 13:14:21.797] I app.loggers.zmq - msg="initializing ZMQ receiver", bind="tcp://localhost:45556"
[2022-07-26 13:14:21.798] I app.loggers.database - msg="initializing database error persistence"
[2022-07-26 13:14:21.802] D app.worker - hint="register task", name="objects-gc"
[2022-07-26 13:14:21.803] D app.worker - hint="register task", name="session-gc"
[2022-07-26 13:14:21.803] D app.worker - hint="register task", name="storage-deleted-gc"
[2022-07-26 13:14:21.803] D app.worker - hint="register task", name="audit-log-gc"
[2022-07-26 13:14:21.803] D app.worker - hint="register task", name="file-xlog-gc"
[2022-07-26 13:14:21.803] D app.worker - hint="register task", name="storage-touched-gc"
[2022-07-26 13:14:21.804] D app.worker - hint="register task", name="audit-log-archive"
[2022-07-26 13:14:21.804] D app.worker - hint="register task", name="tasks-gc"
[2022-07-26 13:14:21.804] D app.worker - hint="register task", name="file-offload"
[2022-07-26 13:14:21.804] D app.worker - hint="register task", name="telemetry"
[2022-07-26 13:14:21.804] D app.worker - hint="register task", name="sendmail"
[2022-07-26 13:14:21.805] D app.worker - hint="register task", name="file-gc"
[2022-07-26 13:14:21.805] I app.worker - hint="cron started", registred-tasks=8
[2022-07-26 13:14:21.809] I app.worker - hint="worker started", name="worker", queue="default"
[2022-07-26 13:14:21.809] I app.srepl - msg="initializing server repl", port=6062, host="127.0.0.1", name="main"
[2022-07-26 13:14:21.810] I app.main - msg="welcome to penpot", version="develop"


tab 2-top:

penpot@978be0c51c7c:~/penpot/exporter$ clojure -M:dev:shadow-cljs watch main
shadow-cljs - server version: 2.17.8 running at http://localhost:9630
shadow-cljs - nREPL server started on port 38441
shadow-cljs - watching build :main
[:main] Configuring build.
[:main] Compiling ...
[:main] Build completed. (211 files, 0 compiled, 0 warnings, 2.68s)

tab2-bottom:

penpot@978be0c51c7c:~/penpot/exporter$ ./scripts/wait-and-start.sh
{:host "localhost", :port 9630, :took 5415}
{:path "target/app.js", :took 7906}
INF [app.core] msg="initializing"
INF [app.browser] hint="initializing browser pool", opts=#js {:max 5, :min 0, :testOnBorrow true, :evictionRunIntervalMillis 5000, :numTestsPerEvictionRun 5, :acquireTimeoutMillis 10000, :idleTimeoutMillis 10000}
INF [app.http] hint="welcome to penpot", module="exporter", version="develop"
INF [app.http] hint="starting http server", port=6061
INF [app.redis] hint="redis connection established", uri="redis://redis/0"
shadow-cljs - #3 ready!

tab-1

penpot@978be0c51c7c:~/penpot/frontend$ clojure -M:dev:shadow-cljs watch main
shadow-cljs - HTTP server available at http://localhost:8888
shadow-cljs - server version: 2.17.8 running at http://localhost:3448
shadow-cljs - nREPL server started on port 3447
shadow-cljs - watching build :main
[:main] Configuring build.
[:main] Compiling ...
[:main] Build completed. (1781 files, 1 compiled, 0 warnings, 6.57s)

when i do that curl command this is what i see in the nginx logs

tail -f /var/log/nginx/error.log

2022/07/26 13:24:12 [error] 34#34: *1 "/home/penpot/penpot/frontend/resources/public/index.html" is forbidden (13: Permission denied), client: 172.177.9.1, server: _, request: "GET / HTTP/1.1", host: "localhost:3449"

That can be the problem, let’s check the permissions on that folder:

docker exec -ti penpot-devenv-main /bin/bash
ls -la /home/penpot/penpot/frontend/resources/public/

Hi guys I too was faced with a similar issue, so after executing command docker exec -ti penpot-devenv-main /bin/bash

cd …
chmod +x /home/penpot
chmod +x /home/penpot/penpot
nginx -s reload

This worked for me

Thank you very much! :pray:

1 Like

That worked !!!

Thank you. Now i am wondering how do i create an account so that i can login ? perhaps this would be a good addition to the devenv setup guide ?

1 Like

Hey,

I too had asked the same question :sweat_smile: :laughing:, so after starting just go to create account on homepage and follow the process and at the same time in another tab go to http://localhost:1080/ here you’ll receive the email verification link and on clicking it you would be able to login.

P.s: I also started clojure recently and working on penpot locally, let’s connect over linkedin :
https://www.linkedin.com/in/vatsalsmehta/ so we can help each other out if we could.

Thanks

1 Like

Hi @vatron

I am using penpot as a hobby to learn front end development. I sent you a connection request in linkedin. Again thank you so much for your help!

Best Regards

2 Likes

@vatron @ymolists I’m learning clojure as well and looking at penpot code as a learning experience … this post was helpful as I had the same 403 forbidden error …

Us chatting about clojure might be a nice small newbies-to-clojure community … Would you care to join my new discord server ? : JoeStar's server

Glad my solution helped you :smile: