Compare commits

...

3 commits

12 changed files with 174 additions and 0 deletions

10
caddy/Caddyfile Normal file
View file

@ -0,0 +1,10 @@
#
# Caddyfile for prod-sourcecamp-starcatsys
# /etc/caddy/Caddyfile
# After modifying, gracefully reload Caddy with `sudo systemctl reload caddy`
#
# Reverse proxy for Forgejo
git.starcat.systems {
reverse_proxy 127.0.0.1:3000
}

6
caddy/README.md Normal file
View file

@ -0,0 +1,6 @@
# Caddyfile
## what
The `Caddyfile` that configures [Caddy](https://caddyserver.com/), used as a reverse proxy for Forgejo.
## where
On the `prod-sourcecamp-starcatsys` server, this file is located at `/etc/caddy/Caddyfile`.

View file

@ -0,0 +1,9 @@
# app.ini
## what
The `app.ini` file for Forgejo. See the [Forgejo Configuration Cheat Sheet](https://forgejo.org/docs/latest/admin/config-cheat-sheet/).
## where
On the `prod-sourcecamp-starcatsys` server, this file is located at `/etc/forgejo/app.ini`.
## env to ini
Some values in the file are shown as `<REDACTED - GITEA__SERVER__LFS_JWT_SECRET>` in place of a secret value. According to [forgejo/contrib/environment-to-ini](https://codeberg.org/forgejo/forgejo/src/branch/forgejo/contrib/environment-to-ini), we should be able to use environment variables for these secrets instead of hard-coding them into the `app.ini` file.

99
forgejo/app_ini/app.ini Normal file
View file

@ -0,0 +1,99 @@
APP_NAME = StarCat Git
APP_SLOGAN = Git repo hosting for StarCat Systems
RUN_USER = git
WORK_PATH = /var/lib/forgejo
RUN_MODE = prod
[database]
DB_TYPE = sqlite3
HOST = 127.0.0.1:3306
NAME = forgejo
USER = forgejo
PASSWD =
SCHEMA =
SSL_MODE = disable
PATH = /var/lib/forgejo/data/forgejo.db
LOG_SQL = false
[repository]
ROOT = /var/lib/forgejo/data/forgejo-repositories
[server]
SSH_DOMAIN = git.starcat.systems
DOMAIN = git.starcat.systems
HTTP_PORT = 3000
ROOT_URL = https://git.starcat.systems/
APP_DATA_PATH = /var/lib/forgejo/data
DISABLE_SSH = false
SSH_PORT = 22
LFS_START_SERVER = true
LFS_JWT_SECRET = <REDACTED - GITEA__SERVER__LFS_JWT_SECRET>
OFFLINE_MODE = true
[lfs]
PATH = /var/lib/forgejo/data/lfs
[mailer]
ENABLED = true
SMTP_ADDR = <REDACTED - GITEA__MAILER__SMTP_ADDR>
SMTP_PORT = 465
FROM = "git.starcat.systems" <git@git.starcat.systems>
USER = git@git.starcat.systems
PASSWD = <REDACTED - GITEA__MAILER__PASSWD>
[service]
REGISTER_EMAIL_CONFIRM = false
ENABLE_NOTIFY_MAIL = true
DISABLE_REGISTRATION = true
ALLOW_ONLY_EXTERNAL_REGISTRATION = false
ENABLE_CAPTCHA = false
REQUIRE_SIGNIN_VIEW = false
DEFAULT_KEEP_EMAIL_PRIVATE = true
DEFAULT_ALLOW_CREATE_ORGANIZATION = true
DEFAULT_ENABLE_TIMETRACKING = true
NO_REPLY_ADDRESS = noreply.git.starcat.systems
[openid]
ENABLE_OPENID_SIGNIN = false
ENABLE_OPENID_SIGNUP = false
[cron.update_checker]
ENABLED = true
[session]
PROVIDER = file
[log]
MODE = console
LEVEL = info
ROOT_PATH = /var/lib/forgejo/log
[repository.pull-request]
DEFAULT_MERGE_STYLE = merge
[repository.signing]
DEFAULT_TRUST_MODEL = committer
[security]
INSTALL_LOCK = true
INTERNAL_TOKEN = <REDACTED - GITEA__SECURITY__INTERNAL_TOKEN>
PASSWORD_HASH_ALGO = pbkdf2_hi
[oauth2]
JWT_SECRET = <REDACTED - GITEA__OAUTH2__JWT_SECRET>
[email.incoming]
ENABLED = true
REPLY_TO_ADDRESS = incoming+%{token}@git.starcat.systems
HOST = <REDACTED - GITEA__EMAIL_0x2E_INCOMING__HOST>
PORT = 993
USERNAME = incoming@git.starcat.systems
PASSWORD = <REDACTED - GITEA__EMAIL_0x2E_INCOMING__PASSWORD>
USE_TLS = false
MAILBOX = Inbox
DELETE_HANDLED_MESSAGE = true
MAXIMUM_MESSAGE_SIZE = 10485760
[ui]
THEMES = forgejo-auto,forgejo-light,forgejo-dark,gitea-auto,gitea-light,gitea-dark
DEFAULT_THEME = gitea-auto

9
forgejo/custom/README.md Normal file
View file

@ -0,0 +1,9 @@
# custom
## what
Customizations made to Forgejo. Please see [admin/customization](https://forgejo.org/docs/latest/admin/customization/) and [contributor/customization](https://forgejo.org/docs/latest/contributor/customization/).
## where
On the `prod-sourcecamp-starcatsys` server, these folders are located within `/var/lib/forgejo/custom/`.
## license note
The StarCat Systems logos found within `custom/public/assets/img` are used under CC-BY-3.0: [Cat by Md Ahasan Habib](https://thenounproject.com/icon/cat-6441095/) from Noun Project.

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

View file

@ -0,0 +1,13 @@
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev/svgjs" width="1000" height="1000"><svg id="SvgjsSvg1001" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 1000 1000">
<defs>
<style>
.cls-1 {
fill: #6fccdd;
stroke-width: 0px;
}
</style>
</defs>
<path class="cls-1" d="M907.9,495.5c50.4-51.5,81.6-122,81.6-199.6,0-157.5-128.2-285.6-285.6-285.6s-285.6,128.2-285.6,285.6,22.9,127.9,61.2,176.5c-278.3,141.7-265.2,452.2-265.1,454.3v14.5c-81.3-18.6-163.4-71.6-163.4-155.7s32.2-121.6,63.4-171.9c29-46.8,59-95.2,59-154.5,0-112.9-50.3-163.2-163.2-163.2v40.8c90.4,0,122.4,32,122.4,122.4s-24.5,87.3-52.9,133c-32.6,52.6-69.5,112.1-69.5,193.4,0,139.2,159.7,204,267.6,204h711.7v-40.8h-81.6v-453.2ZM703.9,51.1c135,0,244.8,109.8,244.8,244.8s-109.8,244.8-244.8,244.8-244.8-109.8-244.8-244.8,109.8-244.8,244.8-244.8ZM255.2,947.7v-22.1c-.6-12.1-11.8-295.1,252.9-421.9,51.2,48.2,120.1,77.9,195.7,77.9s116.9-19,163.2-51.4v418.6h-122.4v-40.8c0-135-109.8-244.8-244.8-244.8v40.8c112.5,0,204,91.5,204,204v40.8h-426c-7.3,0-14.9-.3-22.6-1h0ZM703.9,459.1c90,0,163.2-73.2,163.2-163.2v-163.2l-82.8,62.1c-48.8-27.9-112-27.9-160.8,0l-82.8-62.1v163.2c0,90,73.2,163.2,163.2,163.2h0ZM581.5,214.3l38.9,29.2,23.3-13.3c36.6-20.9,83.8-20.9,120.4,0l23.3,13.2,38.9-29.2v81.6c0,67.5-54.9,122.4-122.4,122.4s-122.4-54.9-122.4-122.4v-81.6h0ZM234.7,290.5l45.8-91.6,91.6-45.8-91.6-45.8L234.7,15.7l-45.8,91.6-91.6,45.8,91.6,45.8,45.8,91.6ZM219.3,137.7l15.4-30.8,15.4,30.8,30.8,15.4-30.8,15.4-15.4,30.8-15.4-30.8-30.8-15.4,30.8-15.4Z"></path>
</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }
@media (prefers-color-scheme: dark) { :root { filter: none; } }
</style></svg>

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 1000 1000">
<defs>
<style>
.cls-1 {
fill: #6fccdd;
stroke-width: 0px;
}
</style>
</defs>
<path class="cls-1" d="M840.3,496.3c42-42.9,68-101.7,68-166.5,0-131.3-106.9-238.2-238.2-238.2s-238.2,106.9-238.2,238.2,19.1,106.7,51,147.2c-232.1,118.2-221.2,377.1-221.1,378.9v12.1c-67.8-15.5-136.3-59.7-136.3-129.8s26.9-101.4,52.9-143.4c24.2-39,49.2-79.4,49.2-128.8,0-94.1-41.9-136.1-136.1-136.1v34c75.4,0,102.1,26.7,102.1,102.1s-20.4,72.8-44.1,110.9c-27.2,43.9-58,93.5-58,161.3,0,116.1,133.2,170.1,223.2,170.1h593.5v-34h-68v-377.9h0ZM670.2,125.7c112.6,0,204.1,91.6,204.1,204.1s-91.6,204.1-204.1,204.1-204.1-91.6-204.1-204.1,91.6-204.1,204.1-204.1h0ZM296,873.4v-18.4c-.5-10.1-9.8-246.1,210.9-351.8,42.7,40.2,100.2,65,163.2,65s97.5-15.8,136.1-42.9v349.1h-102.1v-34c0-112.6-91.6-204.1-204.1-204.1v34c93.8,0,170.1,76.3,170.1,170.1v34h-355.3c-6.1,0-12.4-.3-18.8-.8h0ZM670.2,466c75.1,0,136.1-61,136.1-136.1v-136.1l-69,51.8c-40.7-23.3-93.4-23.3-134.1,0l-69-51.8v136.1c0,75.1,61,136.1,136.1,136.1h0ZM568.1,261.8l32.4,24.4,19.4-11.1c30.5-17.4,69.9-17.4,100.4,0l19.4,11,32.4-24.4v68c0,56.3-45.8,102.1-102.1,102.1s-102.1-45.8-102.1-102.1v-68h0ZM278.9,325.4l38.2-76.4,76.4-38.2-76.4-38.2-38.2-76.4-38.2,76.4-76.4,38.2,76.4,38.2,38.2,76.4ZM266,198l12.8-25.7,12.8,25.7,25.7,12.8-25.7,12.8-12.8,25.7-12.8-25.7-25.7-12.8,25.7-12.8Z"/>
</svg>

After

Width:  |  Height:  |  Size: 1.5 KiB

View file

@ -0,0 +1 @@
<a class="item" href="https://source.camp">Hosted by SourceCamp</a>

View file

@ -0,0 +1,15 @@
{{template "base/head" .}}
<div role="main" aria-label="{{if .IsSigned}}{{ctx.Locale.Tr "dashboard"}}{{else}}{{ctx.Locale.Tr "home"}}{{end}}" class="page-content home">
<div class="tw-mb-8 tw-px-8">
<div class="center">
<img class="logo" width="220" height="220" src="{{AssetUrlPrefix}}/img/logo.svg" alt="{{ctx.Locale.Tr "logo"}}">
<div class="hero">
<h1 class="ui icon header title">
{{AppName}}
</h1>
<h2>{{AppSlogan}}</h2>
</div>
</div>
</div>
</div>
{{template "base/footer" .}}