Skip to content

Commit

Permalink
Add clusterplex Helm chart (#222)
Browse files Browse the repository at this point in the history
* Add initial helm chart

* Added support for Prometheus ServiceMonitor and Grafana Dashboard

* Allow disabling probes
  • Loading branch information
brandan-schmitz authored Jun 20, 2023
1 parent d5019b2 commit 2c29dac
Show file tree
Hide file tree
Showing 14 changed files with 2,145 additions and 1 deletion.
74 changes: 74 additions & 0 deletions .github/workflows/chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: Release Charts

on:
push:
branches:
- master
tags:
- 'v*.*.*'

jobs:
release:
permissions:
contents: write
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v3
with:
path: "src"
fetch-depth: 0

- name: Checkout gh-pages branch
uses: actions/checkout@v3
with:
path: "dest"
ref: "gh-pages"
fetch-depth: 0

- name: Install Helm
uses: azure/setup-helm@v3
with:
version: 3.12.0
token: ${{ secrets.GITHUB_TOKEN }}

- name: Install Helm Docs
run: |
cd /tmp
wget https://github.com/norwoodj/helm-docs/releases/download/v1.11.0/helm-docs_1.11.0_Linux_x86_64.tar.gz
tar -xvf helm-docs_1.11.0_Linux_x86_64.tar.gz
sudo mv helm-docs /usr/local/sbin
- name: Generate Helm Docs
shell: bash
run: |
helm-docs --chart-search-root=src/charts/clusterplex --sort-values-order=file
cp -f src/charts/clusterplex/README.md dest/README.md
- name: Package Helm Chart
shell: bash
run: |
helm package src/charts/clusterplex --dependency-update --destination dest/
- name: Update Chart Index
shell: bash
working-directory: dest
run: |
helm repo index . --url https://pabloromeo.github.io/clusterplex
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v4
id: auto-commit
with:
repository: dest
branch: gh-pages
file_pattern: "index.yaml *.tgz *.md"

- name: Wait for deploy
uses: fountainhead/action-wait-for-check@v1.1.0
if: ${{ steps.auto-commit.outputs.changes_detected }}
id: wait-for-deploy
with:
token: ${{ secrets.GITHUB_TOKEN }}
ref: ${{ steps.auto-commit.outputs.commit_hash }}
checkName: deploy
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,6 @@ typings/
.next

docker-compose.yml

# macOS
**/.DS_STORE
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ Workers require a path to store downloaded codecs for the particular architectur
Codecs are downloaded when the worker container starts up.

The path within the container is **/codecs**, which you can mount to a volume in order to have them persisted across container recreations. Subdirectories for each plex version and architecture are created within it.

## Network settings in PMS ##
Latest versions of ClusterPlex don't require any special network configuration, due to the new **Local Relay** functionality which forwards calls from Workers to Plex, which is enabled by default.

Expand All @@ -91,3 +91,4 @@ See the [docs](docs/) section for details on each component's configuration para
* [On Kubernetes](docs/kubernetes/)
* [On Docker Swarm](docs/docker-swarm/)
* [Grafana Dashboard and Metrics](docs/grafana-dashboard/)
* [On Kubernetes via Helm](https://pabloromeo.github.io/clusterplex)
24 changes: 24 additions & 0 deletions charts/clusterplex/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
README.md.gotmpl
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
6 changes: 6 additions & 0 deletions charts/clusterplex/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dependencies:
- name: common
repository: https://bjw-s.github.io/helm-charts
version: 1.5.1
digest: sha256:3588c89621170f198d4938664d3ea4c469bd91fd78183c83cfcf63f474d348c4
generated: "2023-06-06T20:59:49.839068-05:00"
16 changes: 16 additions & 0 deletions charts/clusterplex/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
apiVersion: v2
name: clusterplex
description: ClusterPlex is basically an extended version of Plex, which supports distributed Workers across a cluster to handle transcoding requests.
type: application
kubeVersion: ">=1.24.0-0"
dependencies:
- name: common
repository: https://bjw-s.github.io/helm-charts
version: 1.5.1
home: https://github.com/pabloromeo/clusterplex/charts/clusterplex
sources:
- https://github.com/pabloromeo/clusterplex
- https://github.com/linuxserver/docker-plex
- https://plex.tv
version: 1.0.0
appVersion: 1.4.4
165 changes: 165 additions & 0 deletions charts/clusterplex/README.md

Large diffs are not rendered by default.

30 changes: 30 additions & 0 deletions charts/clusterplex/README.md.gotmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{ template "chart.header" . }}

{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }}{{ template "chart.appVersionBadge" . }}

{{ template "chart.description" . }}

<br>

{{ template "chart.sourcesSection" . }}

<br>

{{ template "chart.requirementsSection" . }}

<br>

## Installing the Chart

To install the chart with the release name `clusterplex`:

```console
$ helm repo add clusterplex http://pabloromeo.github.io/clusterplex
$ helm install clusterplex clusterplex/clusterplex
```

<br>

{{ template "chart.valuesSection" . }}

{{ template "helm-docs.versionFooter" . }}
Loading

0 comments on commit 2c29dac

Please sign in to comment.