Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add gh-pages #99

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 65 additions & 0 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Documentation

on:
push:
branches: [main]
paths:
- docs/**
pull_request:
branches: [main]
paths:
- docs/**

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: pnpm/action-setup@v4
with:
version: latest

- uses: actions/setup-node@v4
with:
node-version: lts/*
cache: pnpm

- name: Install & build
working-directory: docs
run: |
pnpm i
pnpm build

- name: Upload static files as artifact
id: deployment
uses: actions/upload-pages-artifact@v3 # or specific "vX.X.X" version tag for this action
with:
path: ./docs/build

# Deploy job
deploy:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'

# Add a dependency to the build job
needs: build

# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source

# Deploy to the github-pages environment
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4 # or specific "vX.X.X" version tag for this action
2 changes: 2 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ on:
- "main"
tags:
- "v*.*.*"
paths-ignore:
- "docs/**"

permissions:
contents: read
Expand Down
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
pnpm-lock.yaml
docs/build
1 change: 1 addition & 0 deletions CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
configarr.raydak.de
661 changes: 661 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

172 changes: 7 additions & 165 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Configarr

[![GitHub License](https://img.shields.io/github/license/raydak-labs/configarr)](https://github.com/recyclarr/recyclarr/blob/master/LICENSE)
[![GitHub Release](https://img.shields.io/github/v/release/raydak-labs/configarr?logo=github)](https://github.com/raydak-labs/configarr/releases/)
[![Codacy Badge](https://app.codacy.com/project/badge/Grade/bf3242f8502145d5b4395b9b2aa7c7c6)](https://app.codacy.com/gh/raydak-labs/configarr/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade)
[![Documentation](https://img.shields.io/badge/Documentation-blue)](https://configarr.raydak.de)

Configuration and synchronization tool for Sonarr and Radarr.

Official support only for Sonarr v4 and radarr v5.
Expand Down Expand Up @@ -27,6 +32,8 @@ Other projects:

## Configuration

Full documentation can be found here: https://configarr.raydak.de

- `config.yml`
- Check the template file [template](./config.yml.template) or check the examples.
- You can provide values with the custom tags:
Expand All @@ -43,50 +50,6 @@ See [here](./custom/cfs/)
- See here: https://github.com/PCJones/radarr-sonarr-german-dual-language
- Or good german guide: https://github.com/PCJones/usenet-guide

### How to add own CustomFormats

- You have two ways to provide own custom formats:

- `As file`
- Export from Sonarr/Radarr instance UI (in the CustomFormats list you have two icons for each custom format: clone and export)
- Or use existing custom formats from recyclarr or trash guide
- `As yaml`: You can also directly implement the custom format in the config.
It follows the same keys as the JSON format.

```yaml
# config.yml
customFormatDefinitions:
- trash_id: custom-de-only
trash_scores:
default: -10000
trash_description: "Language: German Only"
name: "Language: Not German"
includeCustomFormatWhenRenaming: false
specifications:
- name: Not German Language
implementation: LanguageSpecification
negate: true
required: false
fields:
value: 4
```

- What you have to add at least is to the field `trash_id` or `configarr_id` to the JSON/YAML.
The ID can be anything you like but should not conflict with other CustomFormats.
Otherwise those will be overwritten during merge process.

```json
{
"configarr_id": "your_own_id",
...other content from export
}
```

- Add it as custom format location in your `config.yml`
- After adding the ID you can simply reference it in the `config.yml` to add it to the QualityProfiles. `localCustomFormatsPath: /your/path/cfs`

> :scroll: You can see an example here [Examples / Full](./examples/full/cfs/custom-size-bigger-40gb.json). Or copy the existing custom formats [custom](./custom/cfs/) in your location.

## Development

1. Optionally setup the local sonarr instance
Expand All @@ -105,124 +68,3 @@ See [here](./custom/cfs/)
## Examples

Some examples for configuration are provided [Examples](./examples/)

## How to run

Required files:

- `config.yml`
- `secrets.yml`

Optional:

- Custom Formats in folders

### Docker

`docker run --rm -v ./:/app/config ghcr.io/raydak-labs/configarr:latest`

### Docker-compose

```yml
services:
configarr:
image: ghcr.io/raydak-labs/configarr:latest

volumes:
- ./config:/app/config # Contains the config.yml and secrets.yml
- ./dockerrepos:/app/repos # Cache repositories
- ./custom/cfs:/app/cfs # Optional if custom formats locally provided
- ./custom/templates:/app/templates # Optional if custom templates
```

### Kubernetes

Example how to run `CronJob` which will regulary sync your configs.

```yml
---
apiVersion: batch/v1
kind: CronJob
metadata:
name: configarr
spec:
schedule: "0 * * * *"
successfulJobsHistoryLimit: 1
failedJobsHistoryLimit: 1
jobTemplate:
spec:
template:
spec:
containers:
- name: configarr
image: ghcr.io/raydak-labs/configarr:latest
imagePullPolicy: Always
tty: true # for color support
envFrom:
- configMapRef:
name: common-deployment-environment
volumeMounts:
- mountPath: /app/repos # Cache repositories
name: app-data
subPath: configarr-repos
- name: config-volume # Mount specifc config
mountPath: /app/config/config.yml
subPath: config.yml
- name: secret-volume
mountPath: /app/config/secrets.yml # Mount secrets
subPath: secrets.yml
volumes:
- name: app-data
persistentVolumeClaim:
claimName: media-app-data
- name: config-volume
configMap:
name: configarr
- name: secret-volume
secret:
secretName: configarr
restartPolicy: Never
---
apiVersion: v1
kind: Secret
metadata:
name: configarr
type: Opaque
stringData:
secrets.yml: |
SONARR_API_KEY: "{{ configarr.sonarrApiKey }}"
---
apiVersion: v1
kind: ConfigMap
metadata:
name: configarr
data:
config.yml: |
trashGuideUrl: https://github.com/TRaSH-Guides/Guides
recyclarrConfigUrl: https://github.com/recyclarr/config-templates

sonarr:
series:
# Set the URL/API Key to your actual instance
base_url: http://sonarr:8989
api_key: !secret SONARR_API_KEY

# Quality definitions from the guide to sync to Sonarr. Choices: series, anime
quality_definition:
type: series

include:
# Comment out any of the following includes to disable them
#### WEB-1080p
- template: sonarr-quality-definition-series
- template: sonarr-v4-quality-profile-web-1080p
- template: sonarr-v4-custom-formats-web-1080p

#### WEB-2160p
- template: sonarr-v4-quality-profile-web-2160p
- template: sonarr-v4-custom-formats-web-2160p

# Custom Formats: https://recyclarr.dev/wiki/yaml/config-reference/custom-formats/
custom_formats: []
radarr: {}
```
20 changes: 20 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Dependencies
/node_modules

# Production
/build

# Generated files
.docusaurus
.cache-loader

# Misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
41 changes: 41 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Configarr documentation

This website is built using [Docusaurus](https://docusaurus.io/), a modern static website generator.

### Installation

```
$ pnpm
```

### Local Development

```
$ pnpm start
```

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.

### Build

```
$ pnpm build
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.

### Deployment

Using SSH:

```
$ USE_SSH=true pnpm deploy
```

Not using SSH:

```
$ GIT_USER=<Your GitHub username> pnpm deploy
```

If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
59 changes: 59 additions & 0 deletions docs/docs/concepts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
sidebar_position: 2
description: "Basic concepts and terminology for understanding Sonarr, Radarr, and custom formats"
keywords: [sonarr, radarr, custom formats, quality profiles, media management, automation]
---

# What are Arr Applications?

This page explains the fundamental concepts and components that Configarr works with. Understanding these will help you make the most of the tool.

## Media Managers

### Sonarr

[Sonarr](https://sonarr.tv/) is a TV series management tool that automates the downloading and organizing of TV shows. It can monitor multiple RSS feeds for new episodes and will grab, sort, and rename them.

### Radarr

[Radarr](https://radarr.video/) is a movie collection manager that works similarly to Sonarr but focuses on movies instead of TV series. It's designed to automatically download and organize movie files.

## Key Terminology

### Custom Formats

Custom formats are rules that help Sonarr and Radarr identify and prioritize specific characteristics of media files. These can include:

- Video quality (HDR, DV, etc.)
- Audio formats (DTS, TrueHD, etc.)
- Release groups
- Language specifications
- Encoding settings

### Quality Profiles

Quality profiles define what types of releases you want for your media. They combine:

- Allowed quality types (1080p, 2160p, etc.)
- Custom format scores
- Upgrade rules
- Minimum/maximum size requirements

### Release Groups

Release groups are teams or individuals who release media content. Different groups often have different standards and specialties for their releases.

### TRaSH Guides

[TRaSH Guides](https://trash-guides.info/) is a comprehensive collection of guides and configurations for various media management tools. It provides recommended settings, custom formats, and quality profiles that represent community best practices.

## How They Work Together

- **Quality Profiles** use **Custom Formats** to score and select releases
- **Sonarr/Radarr** use these profiles to make download decisions
- **TRaSH Guides** provides optimized configurations for both
- **Configarr** helps manage and synchronize all these components

:::tip
For detailed setup instructions and tutorials, visit the official documentation for [Sonarr](https://wiki.servarr.com/sonarr) and [Radarr](https://wiki.servarr.com/radarr).
:::
Loading