go-gitea / gitea

Git with a cup of tea! Painless self-hosted all-in-one software development service, including Git hosting, code review, team collaboration, package registry and CI/CD
https://gitea.com
MIT License
45.24k stars 5.5k forks source link

Installing Docker Root less per the manual using RHEL9. Nothing changed starting it with docker compose up. And nothing works. Banner on top is "Gitea JavaScript code couldn't run correctly, please check your custom templates" #32600

Closed iamtristan closed 4 hours ago

iamtristan commented 15 hours ago

Description

Installing Docker Root less per the manual using RHEL9. Nothing changed starting it with docker compose up. And nothing works. Banner on top is "Gitea JavaScript code couldn't run correctly, please check your custom templates"

This happens before and after installation.

Used the instructions here to the letter.

https://docs.gitea.com/installation/install-with-docker-rootless

Gitea Version

1.22.3

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

RHEL9 via Docker Compose

version: "2"

services: server: image: gitea/gitea:1.22.3-rootless restart: always volumes:

Database

SQLite

wxiaoguang commented 6 hours ago

Gitea JavaScript code couldn't run correctly, please check your custom templates means the outputed page is corrupted.

You could also check page source code and browser's console errors.

There could also be something wrong in your reverse proxy, please make sure every step you have done you could understand, otherwise don't do it.

If there is still a problem, please show a reproducible example with all config and detailed steps.

iamtristan commented 4 hours ago

Hello - Found it. A severely hardened environment.

Here was the problem within NGINX

add_header Content-Security-Policy "default-src 'self'" always;

Thanks wxiaoguang for actually hinting it out :)

iamtristan commented 4 hours ago

Works now with some changes...