Files
portal/public/admin/config.yml
T

54 lines
2.0 KiB
YAML

# Sveltia CMS config — backend: Gitea on the Cyfronet machine (demo). Editors
# log in via Gitea OAuth (PKCE, no client secret); edits are committed to the
# ctao/portal repo. localhost:3000 works both on the machine and through the
# ssh -L tunnel (same port number keeps Gitea's ROOT_URL valid).
# TODO(vhost): switch base_url/api_root to the public Gitea URL once the
# ingress vhost exists (and update the OAuth app's redirect_uris + ROOT_URL).
backend:
name: gitea
repo: ctao/portal
branch: main
base_url: http://localhost:3000
api_root: http://localhost:3000/api/v1
app_id: cf1c44ac-ebe6-4a97-bf2f-f7f26ef1126c
# CTAO branding on the CMS sign-in screen (official Decap/Sveltia option)
logo_url: /brand/CTAO_Logo_login.svg
media_folder: "public/uploads"
public_folder: "/uploads"
collections:
- name: news
label: "News"
label_singular: "Article"
folder: "src/content/news"
create: true
slug: "{{slug}}"
extension: md
format: frontmatter
summary: "{{title}} · {{date}}"
fields:
- { name: title, label: "Title", widget: string }
- { name: description, label: "Short description", widget: text }
- { name: date, label: "Date", widget: datetime, date_format: "YYYY-MM-DD", time_format: false }
- { name: category, label: "Category", widget: string, default: "news" }
- { name: author, label: "Author", widget: string, default: "CTAO" }
- { name: cover, label: "Cover image", widget: image, required: false }
- { name: draft, label: "Draft (unpublished)", widget: boolean, default: false }
- { name: body, label: "Body", widget: markdown }
- name: pages
label: "Pages"
label_singular: "Page"
folder: "src/content/pages"
create: true
slug: "{{slug}}"
extension: md
format: frontmatter
summary: "{{title}}"
fields:
- { name: title, label: "Title", widget: string }
- { name: description, label: "Description", widget: text, required: false }
- { name: body, label: "Body", widget: markdown }