YunoHost-Apps / cockpit_ynh

Cockpit package for YunoHost
https://cockpit-project.org/
GNU General Public License v3.0
8 stars 6 forks source link

Getting message "Please enable javascript" on login page #16

Open Rubonnek opened 2 years ago

Rubonnek commented 2 years ago

Describe the bug

Getting message "Please enable javascript" on login page and I'm unable to access the Cockpit UI.

Context

Steps to reproduce

Expected behavior

I would be greeted by the login page

Logs

Oct 04 18:40:18 mydomain.tld cockpit-ws[4776]: cockpit-ws: couldn't load configuration file: /etc/cockpit/cockpit.conf: Permission denied
Oct 04 18:45:12 mydomain.tld cockpit-ws[5195]: cockpit-ws: Failed to open certificate file /run/cockpit/tls/e3b0c44298fc1c149afbf4c8996fb92427ae41e4>

If applicable and useful, add screenshots to help explain your problem.

Possible fix / workaround

I was able to access Cockpit's login page after executing:

sudo chmod +r /etc/cockpit/cockpit.conf

vinylourson commented 1 year ago

Had the same issue after a fresh install.

Running sudo chmod +r /etc/cockpit/cockpit.conf did fix the issue for me as well.

thomascwells commented 1 year ago

Also fixed the issue for me.

valterbarreira commented 1 year ago

I'm still getting the javascript error, even after running that command. Fresh install on a subdomain.

joeldebruijn commented 1 year ago

Got the same error, checked diagnosis and services, Cockpit service stops every time after restarting the service.

Graninius commented 1 year ago

Had the same issue (fresh installed in subpath) but the command fixed it.

joeldebruijn commented 1 year ago

Had the same issue after a fresh install.

Running sudo chmod +r /etc/cockpit/cockpit.conf did fix the issue for me as well.

I'm fairly new to this, but I understand chmod + r grants read permissions. In the context of Yuno, does this mean the "cockpit" systemuser needs to get reading permissons? Because this command didnt work for me out of the box.

aarontrom commented 1 year ago

I do have the same issue, but that command didn't solve the problem. Does anyone have another idea?

joeldebruijn commented 1 year ago

After a clean cockpit install and using that command the permissions change from:

-r--r----- 1 root cockpit-ws cockpit.conf to

-r--r--r-- 1 root cockpit-ws cockpit.conf

After restarting the cockpit service I still get the same message.

jcn50 commented 1 year ago

@ericgaspar why are those little bugs still not fixed after so long?...

ericgaspar commented 1 year ago

@jcn50 Why ping me? I'm not even the maintainer of this app. As far as i know, you are as responsible as me to fix these little bugs

jcn50 commented 1 year ago

@ericgaspar who is the maintainer? Je comprends pas moi~

ericgaspar commented 1 year ago

who is the maintainer?

Toi, moi, quelqu'un, souvent personne... en l'occurrence pour cockpit, le mainteneur était liberodark mais il ne semble plus actif... Il faut comprendre que les contributions sont souvent sporadiques et limitées par le temps de chacun. Donc si tu as identifié un bug n’hésite pas à faire une PR. (pour info, le catalogue contient plus de 400 apps pour seulement une poignée de volontaires...)

orhtej2 commented 1 year ago

This issue should have been fixed with https://github.com/YunoHost-Apps/cockpit_ynh/commit/bcb7e4ab67c4647452847ba00ef12b3ea8e53915, can you try upgrading normally and confirm if it helps?

jcn50 commented 3 months ago

@orhtej2 : I am still having issues, getting 502 BAD GATEWAY on those:

https://$SUBDOMAIN/cockpit/static/login.js
https://$SUBDOMAIN/cockpit/static/login.css
https://$SUBDOMAIN/cockpit/static/branding.css

After some hours later:

I found out that the installation on a subdomain does not work, it conflicts with the Yunohost SSO~ so it must be installed in a subdirectory, for example: /run So for those with the APP already installed, just edit your installation to do add a path (like /run for example) using the Change the access URL of this application (domain and/or path) setting/operations! Select Cockpit as the default app from the (sub)domain options~.

I don't know why but it was working before on the root of the subdomain~ I can't remember what I did to make it work...

Another problem: I am getting a Limited Access like #17 which I found a fix for~~