forked from dunglas/mercure
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from DEVmachine-fr/feature/add-redis-transport
Feature/add redis transport
- Loading branch information
Showing
124 changed files
with
4,625 additions
and
3,746 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
version: 2 | ||
updates: | ||
- | ||
package-ecosystem: github-actions | ||
directory: / | ||
schedule: | ||
interval: weekly | ||
commit-message: | ||
prefix: ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"tagname-lowercase": true, | ||
"attr-lowercase": true, | ||
"attr-value-double-quotes": true, | ||
"attr-value-not-empty": false, | ||
"attr-no-duplication": true, | ||
"doctype-first": false, | ||
"tag-pair": true, | ||
"tag-self-close": false, | ||
"spec-char-escape": true, | ||
"id-unique": true, | ||
"src-not-empty": true, | ||
"title-require": true, | ||
"alt-require": true, | ||
"doctype-html5": true, | ||
"id-class-value": false, | ||
"style-disabled": false, | ||
"inline-style-disabled": false, | ||
"inline-script-disabled": false, | ||
"space-tab-mixed-disabled": "space", | ||
"id-class-ad-disabled": false, | ||
"href-abs-or-rel": false, | ||
"attr-unsafe-chars": true, | ||
"head-script-disabled": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"threshold": 0, | ||
"reporters": ["consoleFull"], | ||
"ignore": [ | ||
"**/__snapshots__/**", | ||
"**/*_test.go", | ||
"**/examples", | ||
"**/node_modules", | ||
"**/dist", | ||
"**/.goreleaser.yml" | ||
], | ||
"absolute": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
--- | ||
########################### | ||
########################### | ||
## Markdown Linter rules ## | ||
########################### | ||
########################### | ||
|
||
# Linter rules doc: | ||
# - https://github.com/DavidAnson/markdownlint | ||
# | ||
# Note: | ||
# To comment out a single error: | ||
# <!-- markdownlint-disable --> | ||
# any violations you want | ||
# <!-- markdownlint-restore --> | ||
# | ||
|
||
############### | ||
# Rules by id # | ||
############### | ||
MD004: false # Unordered list style | ||
MD007: | ||
indent: 2 # Unordered list indentation | ||
MD010: | ||
ignore_code_languages: [caddyfile] | ||
MD013: false | ||
MD026: | ||
punctuation: ".,;:!。,;:" # List of not allowed | ||
MD029: false # Ordered list item prefix | ||
MD033: false # Allow inline HTML | ||
MD036: false # Emphasis used instead of a heading | ||
|
||
################# | ||
# Rules by tags # | ||
################# | ||
blank_lines: false # Error on blank lines |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"filters": { | ||
"comments": true | ||
}, | ||
"rules": { | ||
"terminology": { | ||
"defaultTerms": true, | ||
"exclude": [ | ||
"(?<=(?:\\w+[^.?!])? )internet\\b(?! explorer)" | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
extends: relaxed | ||
|
||
rules: | ||
line-length: disable | ||
|
||
ignore: | | ||
charts/ | ||
chart/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
|
@@ -20,14 +20,11 @@ jobs: | |
git config user.email "[email protected]" | ||
- name: Install Helm | ||
uses: azure/setup-helm@v1 | ||
with: | ||
version: v3.4.0 | ||
uses: azure/setup-helm@v4 | ||
|
||
- name: Run chart-releaser | ||
uses: dunglas/chart-releaser-action@feat/match-tags | ||
with: | ||
charts_repo_url: https://charts.mercure.rocks | ||
match_tags: helm-chart-* | ||
env: | ||
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Publish Docs | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- docs/** | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 2 | ||
|
||
- name: Revalidate changed pages | ||
run: | | ||
shopt -s globstar | ||
FILES=$(git --no-pager diff --name-only HEAD~1 -- docs/**/*.md | awk 'BEGIN{RS="\n"} {printf "%s%s",sep,$0; sep="&files="}') | ||
curl --silent --fail-with-body "https://mercure.rocks/api/revalidate?secret=${{ secrets.REVALIDATE_TOKEN }}&files=$FILES" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,66 @@ | ||
name: Release Hub | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- 'v*' | ||
- v*.*.* | ||
workflow_dispatch: | ||
inputs: {} | ||
|
||
permissions: write-all | ||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: '1.17' | ||
go-version: '1.22' | ||
cache-dependency-path: | | ||
go.sum | ||
caddy/go.sum | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v2 | ||
if: startsWith(github.ref, 'refs/tags/v') | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Set GoReleaser Git tags | ||
run: | | ||
tags=$(git tag --list --sort=-version:refname 'v*') | ||
echo "GORELEASER_CURRENT_TAG=$(awk 'NR==1 {print;exit}' <<< "$tags")" >> "$GITHUB_ENV" | ||
echo "GORELEASER_PREVIOUS_TAG=$(awk 'NR==2 {print;exit}' <<< "$tags")" >> "$GITHUB_ENV" | ||
- name: Run GoReleaser | ||
uses: goreleaser/goreleaser-action@v4 | ||
uses: goreleaser/goreleaser-action@v5 | ||
with: | ||
version: latest | ||
args: release --clean | ||
args: release --clean --timeout 60m ${{ !startsWith(github.ref, 'refs/tags/v') && '--snapshot --skip=sign' || '' }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Display version | ||
run: dist/caddy_linux_amd64_v1/mercure version | ||
|
||
- name: Upload snapshot | ||
if: ${{ !startsWith(github.ref, 'refs/tags/v') }} | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: snapshot | ||
path: dist/* | ||
retention-days: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,14 @@ | ||
name: Lint and Test Chart | ||
|
||
on: pull_request | ||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- v*.*.* | ||
|
||
jobs: | ||
lint-test: | ||
|
@@ -9,36 +17,36 @@ jobs: | |
CT_TARGET_BRANCH: main | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Helm | ||
uses: azure/setup-helm@v1 | ||
with: | ||
version: v3.4.0 | ||
uses: azure/setup-helm@v4 | ||
|
||
- uses: actions/setup-python@v2 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.7 | ||
python-version: '3.10' | ||
|
||
- name: Set up chart-testing | ||
uses: helm/chart-testing-action@v2.1.0 | ||
uses: helm/chart-testing-action@v2 | ||
|
||
- name: Run chart-testing (list-changed) | ||
id: list-changed | ||
run: | | ||
changed=$(ct list-changed) | ||
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }}) | ||
if [[ -n "$changed" ]]; then | ||
echo "::set-output name=changed::true" | ||
echo "changed=true" >> "$GITHUB_OUTPUT" | ||
fi | ||
- name: Run chart-testing (lint) | ||
run: ct lint --check-version-increment=false | ||
if: steps.list-changed.outputs.changed == 'true' | ||
run: ct lint --check-version-increment=false --target-branch ${{ github.event.repository.default_branch }} | ||
|
||
- name: Create kind cluster | ||
uses: helm/[email protected] | ||
if: steps.list-changed.outputs.changed == 'true' | ||
uses: helm/kind-action@v1 | ||
|
||
- name: Run chart-testing (install) | ||
run: ct install | ||
if: steps.list-changed.outputs.changed == 'true' | ||
run: ct install --target-branch ${{ github.event.repository.default_branch }} |
Oops, something went wrong.