gitea to forgejo migration

This commit is contained in:
nihilist 2025-01-07 18:57:48 +01:00
parent 990c7a084b
commit 1c74b6b14e
26 changed files with 108 additions and 100 deletions

View file

Before

Width:  |  Height:  |  Size: 83 KiB

After

Width:  |  Height:  |  Size: 83 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 82 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 93 KiB

After

Width:  |  Height:  |  Size: 93 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 51 KiB

After

Width:  |  Height:  |  Size: 51 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 230 KiB

After

Width:  |  Height:  |  Size: 230 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 126 KiB

After

Width:  |  Height:  |  Size: 126 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 80 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 63 KiB

After

Width:  |  Height:  |  Size: 63 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 87 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 96 KiB

After

Width:  |  Height:  |  Size: 96 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 95 KiB

After

Width:  |  Height:  |  Size: 95 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 48 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 110 KiB

After

Width:  |  Height:  |  Size: 110 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 58 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 57 KiB

After

Width:  |  Height:  |  Size: 57 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 66 KiB

After

Width:  |  Height:  |  Size: 66 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 161 KiB

After

Width:  |  Height:  |  Size: 161 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 177 KiB

After

Width:  |  Height:  |  Size: 177 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 145 KiB

After

Width:  |  Height:  |  Size: 145 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 51 KiB

After

Width:  |  Height:  |  Size: 51 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 35 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 96 KiB

After

Width:  |  Height:  |  Size: 96 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 47 KiB

Before After
Before After

View file

@ -8,7 +8,7 @@
<meta name="author" content="">
<link rel="shortcut icon" href="../../../../../../assets/img/favicon.png">
<title>Gitea .onion Setup (Anonymous Code Repositories and Collaboration)</title>
<title>Forgejo .onion Setup (Anonymous Code Repositories and Collaboration)</title>
<!-- Bootstrap core CSS -->
<link href="../../assets/css/bootstrap.css" rel="stylesheet">
@ -61,11 +61,17 @@
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<a href="../index.html">Previous Page</a></br></br><p><img src="../../assets/img/user.png" width="50px" height="50px"> <ba>nihilist@mainpc - 2024-11-23</ba></p>
<h1>Gitea .onion Setup (Anonymous Code Repositories and Collaboration) </h1>
<h1>Forgejo .onion Setup (Anonymous Code Repositories and Collaboration) </h1>
<img src="0.png" class="imgRz">
<p>In this tutorial we're going to take a look at how you can setup an anonymous gitea instance that is accessible over Tor, in order to be able to collaborate with people on projects, while maintaining everyone's anonymity. </p>
<p>In this tutorial we're going to take a look at how you can setup an anonymous Forgejo instance (<a href="https://forgejo.org/compare-to-gitea/">which was previously known as Gitea before the hard fork</a>) that is accessible over Tor, in order to be able to collaborate with people on projects, while maintaining everyone's anonymity. </p>
<pre><code class="nim">
Notes on why you should use Forgejo instead of Gitea:
<p><u>Disclaimer:</u> If you are a developer working on projects that aim to reduce governmental control, such as working on privacy-cryptocurrency projects (ie Monero, Haveno, Crypto Mixers, etc), <b>take some time to consider stopping maintaing/contributing to those projects under your public identity</b>, and rather shift to maintaining those projects under an anonymous identity (which is the aim of the following Gitea setup). </p>
<b>Forgejo was created in October 2022 after a for profit company took over the Gitea project.</b> It exists under the umbrella of a non-profit organization, Codeberg e.V. and is developed in the interest of the general public. In the year that followed, this difference in governance led to choices that made Forgejo significantly and durably different from Gitea.
</pre></code>
<p><u>Disclaimer:</u> If you are a developer working on projects that aim to reduce governmental control, such as working on privacy-cryptocurrency projects (ie Monero, Haveno, Crypto Mixers, etc), <b>take some time to consider stopping maintaing/contributing to those projects under your public identity</b>, and rather shift to maintaining those projects under an anonymous identity (which is the aim of the following Forgejo setup). </p>
<p><b>You never know when your tyrannical government is going to snap and decide to make an example out of you, just like what happened to <a href="https://www.coindesk.com/policy/2024/05/14/tornado-cash-developer-alexey-pertsev-found-guilty-of-money-laundering/">Tornado Cash</a></b>. It is a matter of <a href="../internetsegmentation/index.html">adapting your OPSEC to the intended internet use</a>. Don't paint a target on your back and give any ammunition to the adversary, because they're going to shoot you with everything you give them (your IRL name, what you contributed on the project, taking things you said out of context, etc). <b>Tyrants don't care, even if it they have to step on your freedom of speech</b> (as that's what developing code is) to keep their control over the masses, they will do anything to keep their control intact.</p>
</div>
@ -85,15 +91,15 @@
<p>Now the problem with trusting a business to host your code repositories that reduces governmental control (such as <a href="https://decrypt.co/107053/it-doesnt-change-anything-says-tornado-cash-code-disappears-github">Tornado Cash</a>) is that those governments can use any company (such as Microsoft in particular) to do their bidding, <b>such as infringing on your freedom of speech, censoring you and deleting your work from the platform.</b></p>
<p>The source code for crypto transaction mixer Tornado Cash has disappeared from Github <b>barely 24 hours after the US Treasury Department added the privacy tool to its sanctions list.</b> Highlighting how Microsoft is a proxy that the US Government uses (more often than you think) to persecute anyone they don't like. </p>
<img src="1.png" class="imgRz">
<p> <b>That is why Github should not be relied on to host any code repository that threaten governmental control</b>, we need an alternative that we can host ourselves, to break free from that governmental control. Which is where Gitea comes in the picture.</p>
<p>Gitea is a painless, self-hosted, all-in-one software development service. It includes Git hosting, code review, team collaboration, package registry, and CI/CD. It is similar to GitHub, Bitbucket and GitLab. The most important part being that it can be self-hosted.</b></p>
<p> <b>That is why Github should not be relied on to host any code repository that threaten governmental control</b>, we need an alternative that we can host ourselves, to break free from that governmental control. Which is where Forgejo comes in the picture.</p>
<p>Forgejo is a painless, self-hosted, all-in-one software development service. It includes Git hosting, code review, team collaboration, package registry, and CI/CD. It is similar to GitHub, Bitbucket and GitLab. The most important part being that it can be self-hosted.</b></p>
<img src="3.png" class="imgRz">
<p>Now let's suppose you setup your potentially sensitive repositories on a clearnet gitea instance (meaning the server can be reached directly by a domain name, to it's public IP address. <b>What is stopping the tyrannical government from ordering the VPS provider to shut down the server ?</b> They know where it is located, what server it is on, so they can order it to be taken down all the same, as they will simply force another business to comply with their demands, and this time it will be the server itself that will be taken down.</p>
<p>Now let's suppose you setup your potentially sensitive repositories on a clearnet forgejo instance (meaning the server can be reached directly by a domain name, to it's public IP address. <b>What is stopping the tyrannical government from ordering the VPS provider to shut down the server ?</b> They know where it is located, what server it is on, so they can order it to be taken down all the same, as they will simply force another business to comply with their demands, and this time it will be the server itself that will be taken down.</p>
</br>
</br>
<h2><u>OPSEC RECOMMENDATIONS:</u></h2>
<p>This is why the gitea instance needs to be setup behind Tor, as a <a href="../torwebsite/index.html">.onion hidden service</a>. Now you have a few options as to where to host the the gitea service. It can be on a <a href="../anonymousremoteserver/index.html">remote VPS that you acquired anonymously</a> (where the cost will be the renting of that VPS, such as 5 euros per month):</p>
<p>This is why the Forgejo instance needs to be setup behind Tor, as a <a href="../torwebsite/index.html">.onion hidden service</a>. Now you have a few options as to where to host the the Forgejo service. It can be on a <a href="../anonymousremoteserver/index.html">remote VPS that you acquired anonymously</a> (where the cost will be the renting of that VPS, such as 5 euros per month):</p>
<img src="../hiddenservice/1.png" class="imgRz">
<p>Or it can simply be on a server that is running at your own home, at the cost of your own elecricity consumption, and internet connection:</p>
<img src="../hiddenservice/0.png" class="imgRz">
@ -106,7 +112,7 @@
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2><b>Gitea instance Setup</b></h2> </br> </br>
<h2><b>Forgejo instance Setup</b></h2> </br> </br>
<p>Now that we laid out the justifications for this setup, let's set it up on our server using Docker:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv]
@ -116,142 +122,144 @@
→ cd /srv
[ Datura ] [ /dev/pts/13 ] [/srv]
→ mkdir gitea_onion
→ mkdir forgejo_onion
[ Datura ] [ /dev/pts/13 ] [/srv]
→ cd gitea_onion
→ cd forgejo_onion
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv]
→ cat docker-compose.yml
version: "3"
networks:
gitea:
forgejo:
external: false
services:
server:
image: gitea/gitea:latest
container_name: gitea-onion
image: codeberg.org/forgejo/forgejo:9.0.3
container_name: forgejo
environment:
- USER_UID=1000
- USER_GID=1000
restart: always
networks:
- gitea
- tor
- forgejo
- tor-forgejo
volumes:
- ./gitea:/data
- ./forgejo:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
ports:
- "127.0.0.1:3019:3000"
- "127.0.0.1:3009:3000"
- "127.0.0.1:2222:22"
tor:
tor-forgejo:
image: osminogin/tor-simple
container_name: tor
container_name: tor-forgejo
volumes:
- ./tor-data:/var/lib/tor
- ./tor-data/torrc:/etc/tor
networks:
- tor
- tor-forgejo
networks:
tor:
gitea:
tor-forgejo:
forgejo:
</pre></code>
<p>Now let's setup a docker Tor daemon and the folder it needs to have, as we'll later need gitea to connect elsewhere through Tor :</p>
<p>Now let's setup a docker Tor daemon and the folder it needs to have, as we'll later need Forgejo to connect elsewhere through Tor :</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ mkdir -p tor-data/torrc
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ vim tor-data/torrc/torrc
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ cat tor-data/torrc/torrc
SOCKSPort 0.0.0.0:9050
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ chown -R 100:65533 tor-data/
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ chmod 700 tor-data
</code></pre>
<p>now before we run the gitea instance, we need to make it reachable via a .onion domain, so let's install tor and generate a .onion domain by following <a href="../torwebsite/index.html">this tutorial</a></a>: </p>
<p>now before we run the Forgejo instance, we need to make it reachable via a .onion domain, so let's install tor and generate a .onion domain by following <a href="../torwebsite/index.html">this tutorial</a></a>: </p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/mkp224o]
→ ls /var/lib/tor/onions/daturab6drmkhyeia4ch5gvfc2f3wgo6bhjrv3pz6n7kxmvoznlkq4yd.onion
authorized_clients hostname hs_ed25519_public_key hs_ed25519_secret_key
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ cat /etc/tor/torrc | tail -n 5
HiddenServiceDir /var/lib/tor/onions/daturab6drmkhyeia4ch5gvfc2f3wgo6bhjrv3pz6n7kxmvoznlkq4yd.onion/
HiddenServicePort 80 127.0.0.1:3019
HiddenServicePort 2222 127.0.0.1:2222
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ systemctl restart tor@default
</code></pre>
<p>Now that's done, we launch gitea by using docker-compose:</p>
<p>Now that's done, we launch Forgejo by using docker-compose:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ docker-compose up
Creating gitea-onion ... done
Attaching to gitea-onion
gitea-onion | Generating /data/ssh/ssh_host_ed25519_key...
gitea-onion | Generating /data/ssh/ssh_host_rsa_key...
gitea-onion | Generating /data/ssh/ssh_host_ecdsa_key...
gitea-onion | Server listening on :: port 22.
gitea-onion | Server listening on 0.0.0.0 port 22.
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:242:runWeb() [I] Starting Gitea on PID: 15
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:111:showWebStartupMessage() [I] Gitea version: 1.22.3 built with GNU Make 4.4.1, go1.22.8 : bindata, timetzdata, sqlite, sqlite_unlock_notify
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:112:showWebStartupMessage() [I] * RunMode: prod
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:113:showWebStartupMessage() [I] * AppPath: /usr/local/bin/gitea
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:114:showWebStartupMessage() [I] * WorkPath: /data/gitea
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:115:showWebStartupMessage() [I] * CustomPath: /data/gitea
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:116:showWebStartupMessage() [I] * ConfigFile: /data/gitea/conf/app.ini
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:117:showWebStartupMessage() [I] Prepare to run install page
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:304:listen() [I] Listen: http://0.0.0.0:3000
gitea-onion | 2024/11/23 16:37:01 cmd/web.go:308:listen() [I] AppURL(ROOT_URL): http://localhost:3000/
gitea-onion | 2024/11/23 16:37:01 ...s/graceful/server.go:50:NewServer() [I] Starting new Web server: tcp:0.0.0.0:3000 on PID: 15
Creating forgejo-onion ... done
Attaching to forgejo-onion
forgejo-onion | Generating /data/ssh/ssh_host_ed25519_key...
forgejo-onion | Generating /data/ssh/ssh_host_rsa_key...
forgejo-onion | Generating /data/ssh/ssh_host_ecdsa_key...
forgejo-onion | Server listening on :: port 22.
forgejo-onion | Server listening on 0.0.0.0 port 22.
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:242:runWeb() [I] Starting Forgejo on PID: 15
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:111:showWebStartupMessage() [I] Forgejo version: 1.22.3 built with GNU Make 4.4.1, go1.22.8 : bindata, timetzdata, sqlite, sqlite_unlock_notify
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:112:showWebStartupMessage() [I] * RunMode: prod
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:113:showWebStartupMessage() [I] * AppPath: /usr/local/bin/gitea
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:114:showWebStartupMessage() [I] * WorkPath: /data/gitea
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:115:showWebStartupMessage() [I] * CustomPath: /data/gitea
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:116:showWebStartupMessage() [I] * ConfigFile: /data/gitea/conf/app.ini
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:117:showWebStartupMessage() [I] Prepare to run install page
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:304:listen() [I] Listen: http://0.0.0.0:3000
forgejo-onion | 2024/11/23 16:37:01 cmd/web.go:308:listen() [I] AppURL(ROOT_URL): http://localhost:3000/
forgejo-onion | 2024/11/23 16:37:01 ...s/graceful/server.go:50:NewServer() [I] Starting new Web server: tcp:0.0.0.0:3000 on PID: 15
</code></pre>
<p>Now that's done, let's access our gitea instance from the tor browser at the .onion domain we set for it, to setup the initial configuration:</p>
<p>Now that's done, let's access our Forgejo instance from the tor browser at the .onion domain we set for it, to setup the initial configuration:</p>
<img src="4.png" class="imgRz">
<p>Take note that you can leave everything as it is by default here, except if you want to change the Site Title, take note that there is no need for https in the URL, it is normal for it to remain http. And lastly let's disable registrations, <b>as users won't be using emails to register since we're not going to use the clearnet at all.</b></p>
<img src="5.png" class="imgRz">
<p>Lastly don't forget to create the administrator account at the bottom, and click "Install Gitea":</p>
<p>Lastly don't forget to create the administrator account at the bottom, and click "Install Forgejo":</p>
<img src="6.png" class="imgRz">
<p>Wait a bit for the gitea instance to finish setup, and you're done!</p>
<p>Wait a bit for the Forgejo instance to finish setup, and you're done!</p>
<img src="7.png" class="imgRz">
<p>Now we need to tweak the instance a bit, so let's edit the app.ini file that is located in <b>/srv/gitea_onion/gitea/gitea/conf/app.ini</b>:</p>
<p>Now we need to tweak the instance a bit, so let's edit the app.ini file that is located in <b>/srv/forgejo_onion/gitea/gitea/conf/app.ini</b>:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion]
→ ls
docker-compose.yml gitea
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion]
→ cd gitea
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion/gitea]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion/gitea]
→ ls
git gitea ssh
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion/gitea]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion/gitea]
→ cd gitea
[ Datura ] [ /dev/pts/6 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/6 ] [forgejo_onion/gitea/gitea]
→ ls
actions_artifacts attachments conf home jwt packages repo-archive sessions
actions_log avatars gitea.db indexers log queues repo-avatars tmp
[ Datura ] [ /dev/pts/6 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/6 ] [forgejo_onion/gitea/gitea]
→ cd conf
[ Datura ] [ /dev/pts/6 ] [gitea/gitea/conf]
@ -273,13 +281,13 @@ DEFAULT_THEME = gitea-dark
</pre></code>
<p>dont forget to restart the gitea docker everytime you edit the app.ini config file:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ docker-compose down ; docker-compose up -d
Stopping gitea-onion ... done
Removing gitea-onion ... done
Removing network gitea_onion_gitea
Creating network "gitea_onion_gitea" with the default driver
Creating gitea-onion ... done
Stopping forgejo-onion ... done
Removing forgejo-onion ... done
Removing network forgejo_onion_gitea
Creating network "forgejo_onion_gitea" with the default driver
Creating forgejo-onion ... done
</pre></code>
<p>then on the webpage, hit "Ctrl+F5" to refresh the page and see the new theme:</p>
@ -293,20 +301,20 @@ Creating gitea-onion ... done
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2><b>Gitea mirroring Github repositories through Tor</b></h2> </br> </br>
<p>Now in order to make sure our gitea instance is able to mirror external git repositories from other websites such as github, we need to make sure it goes through Tor to do so, so we need to make sure the gitea container can reach the docker tor daemon, so have to make sure it uses it by adding the [proxy] section in the app.ini config file (<u>Sidenote:</u> the Gitea container will know that the "tor" hostname refers to the tor docker container, so it is totally intentional as written below):</p>
<h2><b>Forgejo mirroring Github repositories through Tor</b></h2> </br> </br>
<p>Now in order to make sure our Forgejo instance is able to mirror external git repositories from other websites such as github, we need to make sure it goes through Tor to do so, so we need to make sure the gitea container can reach the docker tor daemon, so have to make sure it uses it by adding the [proxy] section in the app.ini config file (<u>Sidenote:</u> the Forgejo container will know that the "tor" hostname refers to the tor docker container, so it is totally intentional as written below):</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ vim gitea/gitea/conf/app.ini
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ cat gitea/gitea/conf/app.ini | tail -n 4
[proxy]
PROXY_ENABLED = true
PROXY_URL = <b>socks://tor:9050/</b>
PROXY_URL = <b>socks://tor-forgejo:9050/</b>
PROXY_HOSTS = *
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ docker-compose down ; docker-compose up -d
</pre></code>
@ -328,8 +336,8 @@ PROXY_HOSTS = *
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2><b>Handling gitea repositories through Tor</b></h2> </br> </br>
<p>So now let's create our first gitea repository from the web interface:</p>
<h2><b>Handling Forgejo repositories through Tor</b></h2> </br> </br>
<p>So now let's create our first Forgejo repository from the web interface:</p>
<img src="14.png" class="imgRz">
<img src="15.png" class="imgRz">
<p>Now that the repository has been created, we need to push our first commit there so let's follow the instructions: </p>
@ -371,7 +379,7 @@ Switched to a new branch 'main'
create mode 100644 README.md
</code></pre>
<p>Then we can proceed with the rest of the instructions to push the commit to the repository via the .onion gitea domain, with the exception of the <b>git push</b> command, where we need to use the <b>torsocks</b> in front of it, because otherwise it won't be able to resolve the .onion domain:</p>
<p>Then we can proceed with the rest of the instructions to push the commit to the repository via the .onion Forgejo domain, with the exception of the <b>git push</b> command, where we need to use the <b>torsocks</b> in front of it, because otherwise it won't be able to resolve the .onion domain:</p>
<pre><code class="nim">
[ mainpc ] [ /dev/pts/9 ] [~/Documents/my-very-cool-repository]
→ git remote add origin http://daturab6drmkhyeia4ch5gvfc2f3wgo6bhjrv3pz6n7kxmvoznlkq4yd.onion/nihilist/my-very-cool-repository.git
@ -404,7 +412,7 @@ remote: Total 3 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Receiving objects: 100% (3/3), done.
</pre></code>
<p>Next, if you want other people to contribute to your gitea projects, you'll have to do manual registrations as they can't use email to register new accounts:</p>
<p>Next, if you want other people to contribute to your Forgejo projects, you'll have to do manual registrations as they can't use email to register new accounts:</p>
<img src="20.png" class="imgRz">
<img src="21.png" class="imgRz">
<img src="22.png" class="imgRz">
@ -419,16 +427,16 @@ Receiving objects: 100% (3/3), done.
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2><b>BONUS: Customizing Gitea's appearance</b></h2> </br> </br>
<p>Now if you want to customize your gitea instance like i did at <a href="https://git.nowhere.moe">https://git.nowhere.moe</a> you'll can first create the templates folder to change the homepage:</p>
<h2><b>BONUS: Customizing Forgejo's appearance</b></h2> </br> </br>
<p>Now if you want to customize your Forgejo instance like i did at <a href="https://git.nowhere.moe">https://git.nowhere.moe</a> you'll can first create the templates folder to change the homepage:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ cd gitea/gitea
[ Datura ] [ /dev/pts/13 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/13 ] [forgejo_onion/gitea/gitea]
→ mkdir templates
[ Datura ] [ /dev/pts/13 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/13 ] [forgejo_onion/gitea/gitea]
→ cd templates
[ Datura ] [ /dev/pts/6 ] [gitea/gitea/templates]
@ -442,19 +450,19 @@ Receiving objects: 100% (3/3), done.
<h2>A painful, self-inflicted Nightmare </h2>
[ Datura ] [ /dev/pts/13 ] [gitea/gitea/templates]
→ cd /srv/gitea_onion
→ cd /srv/forgejo_onion
[ Datura ] [ /dev/pts/13 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/13 ] [/srv/forgejo_onion]
→ docker-compose down ; docker-compose up -d
</code></pre>
<img src="17.png" class="imgRz">
<p>then to change the logo you can drop your own custom logos in the <b>/srv/gitea_onion/gitea/gitea/public/assets/img/</b> directory:</p>
<p>then to change the logo you can drop your own custom logos in the <b>/srv/forgejo_onion/gitea/gitea/public/assets/img/</b> directory:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/6 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/6 ] [forgejo_onion/gitea/gitea]
→ mkdir public/assets/img
[ Datura ] [ /dev/pts/6 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/6 ] [forgejo_onion/gitea/gitea]
→ cd public/assets/img
[ Datura ] [ /dev/pts/6 ] [public/assets/img]
@ -463,17 +471,17 @@ apple-touch-icon.png favicon.png gitea-192.png gitea-lg.png gitea-sm.png
favicon.ico favicon.svg gitea-512.png gitea-safari.svg gitea.svg logo.svg
[ Datura ] [ /dev/pts/6 ] [public/assets/img]
→ cd /srv/gitea_onion
→ cd /srv/forgejo_onion
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion]
→ docker-compose down ; docker-compose up -d
</code></pre>
<p>Then, simply refresh the page to see the changes:</p>
<img src="18.png" class="imgRz">
<p>Next, if you want a custom CSS theme like the one i have, <b>first be aware that as gitea continues to be updated, the CSS theme may break depending on the breaking changes that gitea introduces, it is safer to keep using the default gitea-dark theme.</b> If that's not a problem for you, you can download it from <a href="https://git.nowhere.moe/nihilist/Datura-Network/raw/branch/main/2-Decentralization/gitea/gitea/gitea/public/assets/css/theme-space.css">here</a> and put it in the <b>/srv/gitea_onion/gitea/gitea/public/assets/css/</b> directory:</p>
<p>Next, if you want a custom CSS theme like the one i have, <b>first be aware that as Forgejo continues to be updated, the CSS theme may break depending on the breaking changes that gitea introduces, it is safer to keep using the default gitea-dark theme.</b> If that's not a problem for you, you can download it from <a href="https://git.nowhere.moe/nihilist/Datura-Network/raw/branch/main/2-Decentralization/gitea/gitea/gitea/public/assets/css/theme-space.css">here</a> and put it in the <b>/srv/forgejo_onion/gitea/gitea/public/assets/css/</b> directory:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion]
→ cd gitea/gitea/public/assets
[ Datura ] [ /dev/pts/6 ] [gitea/public/assets]
@ -497,12 +505,12 @@ theme-space.css 100%[============================================
</code></pre>
<p>Then make sure this is the default theme that is used, from the app.ini config file, and restart the gitea instance to refresh the configuration:</p>
<p>Then make sure this is the default theme that is used, from the app.ini config file, and restart the Forgejo instance to refresh the configuration:</p>
<pre><code class="nim">
[ Datura ] [ /dev/pts/6 ] [public/assets/css]
→ cd ../../../
[ Datura ] [ /dev/pts/6 ] [gitea_onion/gitea/gitea]
[ Datura ] [ /dev/pts/6 ] [forgejo_onion/gitea/gitea]
→ cd conf
[ Datura ] [ /dev/pts/6 ] [gitea/gitea/conf]
@ -522,14 +530,14 @@ THEMES = space, gitea-dark</b>
[ Datura ] [ /dev/pts/6 ] [gitea/gitea/conf]
→ cd ../../..
[ Datura ] [ /dev/pts/6 ] [/srv/gitea_onion]
[ Datura ] [ /dev/pts/6 ] [/srv/forgejo_onion]
→ docker-compose down ; docker-compose up -d
</pre></code>
<img src="19.png" class="imgRz">
<p>And that's it! You managed to get a customized .onion-only gitea instance, effectively forcing whoever that wants to use it to remain anonymous, if they want to deanonymize themselves, it will be out of their own accord later on.</p>
<p>And that's it! You managed to get a customized .onion-only Forgejo instance, effectively forcing whoever that wants to use it to remain anonymous, if they want to deanonymize themselves, it will be out of their own accord later on.</p>
</div>
</div><!-- /row -->

View file

@ -50,11 +50,11 @@
<li>⭐: Personal Favorite</li>
<li>✅: Completed</li>
<li>🟠: Work in progress</li>
<li>❌: Not started yet (can be brainstormed on their assigned gitea issues <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/projects/1">here</a>)</li>
<li>❌: Not started yet (can be brainstormed on their assigned Forgejo issues <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/projects/1">here</a>)</li>
</ol></br>
<b>⚠️ This Blog is open to contributions:</b>
<p>If you want to contribute, check out the gitea repository for contributions (along with the guidelines) <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions">here</a>, check out the project board <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/projects/1">here</a> to know the status of which tutorial being assigned to whom. <b>(i'm rewarding 10 to 50 euros in monero per new complete blogpost, as advertised on <a href="https://xmrbazaar.com/listing/UsWA/">Xmrbazaar</a>)</b>. if the blogpost you want to contribute is not listed below, contact me directly so that I can validate your blogpost idea beforehand. <b>For a step-by-step tutorial on how to contribute, please check out <a href="contribute/index.html">this tutorial</a>.</b></p>
<p>If you want to contribute, check out the Forgejo repository for contributions (along with the guidelines) <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions">here</a>, check out the project board <a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/projects/1">here</a> to know the status of which tutorial being assigned to whom. <b>(i'm rewarding 10 to 50 euros in monero per new complete blogpost, as advertised on <a href="https://xmrbazaar.com/listing/UsWA/">Xmrbazaar</a>)</b>. if the blogpost you want to contribute is not listed below, contact me directly so that I can validate your blogpost idea beforehand. <b>For a step-by-step tutorial on how to contribute, please check out <a href="contribute/index.html">this tutorial</a>.</b></p>
</div>
@ -252,7 +252,7 @@
<li><a href="anonymousremoteserver/index.html">✅ How to rent remote servers anonymously (Cloud resellers) ⭐</a><img src="logos/Tor.png" class="logo"><img src="logos/kycnotme.webp" class="logo"><img src="logos/vps.png" class="logo"></li>
<li><a href="torwebsite/index.html">✅ Hidden Service with custom .onion Vanity V3 address</a><img src="logos/Tor.png" class="logo"><img src="logos/torbrowser.png" class="logo"></li>
<li><a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/issues/179">❌ How to Verify one's Identity while maintaining Anonymity using PGP canaries ?</a><img src="logos/gnupg.png" class="logo"></li>
<li><a href="gitea-anon/index.html">✅ Gitea .onion Setup (Anonymous Code Repositories and Collaboration)</a><img src="logos/gitea.png" class="logo"><img src="logos/Tor.png" class="logo"></li>
<li><a href="forgejo-anon/index.html">✅ Forgejo .onion Setup (Anonymous Code Repositories and Collaboration)</a><img src="logos/Forgejo.png" class="logo"><img src="logos/Tor.png" class="logo"></li>
<li><a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/issues/47">❌ How to setup Nerostr (Nostr blogging)</a><img src="logos/nostr.png" class="logo"><img src="logos/Tor.png" class="logo"><img src="logos/monero.png" class="logo"></li>
<li><a href="http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/issues/116">❌ How to setup a .onion Lemmy instance (to replace Reddit)</a><img src="logos/Tor.png" class="logo"><img src="logos/monero.png" class="logo"></li>
</br>