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

[BREAKING] feat/refactor/docs: multiple providers, large refactor, configurable ticking interval, fix for jwks endpoint has different host #99

Open
wants to merge 36 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
994cb31
feat(discovery): multiple oidc providers
antonengelhardt Sep 5, 2024
6e9f61b
refactor: split into separate files
antonengelhardt Sep 5, 2024
301ba4c
chore: pr template
antonengelhardt Sep 5, 2024
7866042
refactor: error page is now generic
antonengelhardt Sep 5, 2024
3315846
style: fmt
antonengelhardt Sep 5, 2024
f36a1ba
style: clippy lints fixed
antonengelhardt Sep 5, 2024
74060f7
fix: add footer to auth page and layout fixes
antonengelhardt Sep 5, 2024
273ec33
chore(deps): bump serde, serde_json, regex & sort deps
antonengelhardt Sep 6, 2024
47690cf
docs: move social-graphic to .github/assets
antonengelhardt Sep 9, 2024
4c72c56
style(fmt): order modules
antonengelhardt Sep 9, 2024
b70a756
fix(discovery): implement Display for ResolverState
antonengelhardt Sep 9, 2024
8b03a41
fix(logs): pretty print discovery reponses debug logs
antonengelhardt Sep 9, 2024
c63bcc1
refactor/docs: naming change, more comments and log level changes
antonengelhardt Sep 9, 2024
b7d4ea0
fix(logs): lower case log
antonengelhardt Sep 9, 2024
0cfa8c9
fix(html): fixed height for all providers cards
antonengelhardt Sep 9, 2024
866e100
docs: update readme and examples with multiple providers logic
antonengelhardt Sep 9, 2024
b4a5a61
feat(discovery): configurable `ticking_interval_in_ms` controls ticking
antonengelhardt Sep 9, 2024
d68a36a
style: fmt
antonengelhardt Sep 9, 2024
b6f3a13
fix(discovery): fix if host of jwks endpoint is different
antonengelhardt Sep 9, 2024
5b0b1a2
fix(exclude): get scheme to parse url
antonengelhardt Sep 9, 2024
b520a42
feat(errors): use envoy's request-id to log errors and show, helvetica
antonengelhardt Sep 10, 2024
a5ae4be
refactor: rebase logout path PR with mulitple providers PR
antonengelhardt Sep 6, 2024
8b1faf3
fix(logout): write something to clear the cookie, refactor cookie fn
antonengelhardt Sep 12, 2024
8bc79b9
feat(ci): add audit, outdated and verify-project steps
antonengelhardt Oct 17, 2024
025195f
chore(deps): update envoy to 1.30
antonengelhardt Oct 17, 2024
f5073fa
chore(deps): update regex to 1.11 and thiserror to 1.0.64
antonengelhardt Oct 17, 2024
5b9dc69
fix(ci): run test jobs more quickly
antonengelhardt Oct 17, 2024
a9cda9d
chore: add audit.toml file
antonengelhardt Oct 17, 2024
a9feaba
fix(html): error page has dark mode now!
antonengelhardt Oct 18, 2024
1f103bb
style: use inline variables in html.rs
miwig Oct 18, 2024
de45f7a
fix: store number of cookie parts in a cookie
miwig Oct 18, 2024
822cbfd
style: use inline formatting in errors.rs
miwig Oct 21, 2024
43a4ce7
chore: remove dead code
miwig Oct 21, 2024
bbc17e7
chore(deps): update 4 deps
antonengelhardt Nov 4, 2024
9c4c076
refactor: `wasm32-wasi` renamed to `wasm32-wasip1` & rust to 1.78
antonengelhardt Nov 4, 2024
db8f721
chore(deps): update thiserror to 1.0.68
antonengelhardt Nov 4, 2024
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
File renamed without changes
6 changes: 4 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@

<!-- 🚀 This PR does **not** introduce a breaking change -->

<!-- ⚠️ This PR introduces a breaking change:
- ...
<!--
> [!WARNING]
> This PR introduces a breaking change:
> - ...
-->

## Other information and Screenshots (if appropriate)
Expand Down
18 changes: 12 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
cargo-deny:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -26,7 +26,7 @@ jobs:
clippy:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -41,17 +41,19 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Rust version
run: rustc --version && cargo --version

- name: Clippy
run: cargo clippy --release --all-targets --target=wasm32-wasi -- -D warnings
run: cargo clippy --release --all-targets --target=wasm32-wasip1 -- -D warnings

fmt:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -65,7 +67,7 @@ jobs:
test:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -80,6 +82,8 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Rust version
run: rustc --version && cargo --version
Expand Down Expand Up @@ -107,10 +111,12 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Build wasm-oidc-plugin
run: |
cargo build --target wasm32-wasi --release
cargo build --target wasm32-wasip1 --release

- name: Upload plugin as artifact
uses: actions/upload-artifact@v4
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
name: Build and upload artifacts
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -25,10 +25,12 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Build
run: |
cargo build --target wasm32-wasi --release
cargo build --target wasm32-wasip1 --release

- name: Archive production artifacts
uses: actions/upload-artifact@v4
Expand Down
89 changes: 79 additions & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
cargo-deny:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -21,7 +21,7 @@ jobs:
clippy:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -36,19 +36,19 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Rust version
run: rustc --version && cargo --version

- name: Clippy
run: |
rustc --version && cargo --version
cargo clippy --release --all-targets --target=wasm32-wasi -- -D warnings
cargo clippy --release --all-targets --target=wasm32-wasip1 -- -D warnings

fmt:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -59,10 +59,75 @@ jobs:
- name: Fmt
run: cargo fmt -- --check

audit:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Install cargo audit
run: cargo install cargo-audit

- name: Audit
run: cargo audit -f audit.toml

verify-project:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Rust version
run: rustc --version && cargo --version

- name: Verify project
run: cargo verify-project

outdated:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Install cargo-outdated
run: cargo install cargo-outdated

- name: Rust version
run: rustc --version && cargo --version

- name: Outdated
run: cargo outdated --root-deps-only --exit-code 1

test:
runs-on: ubuntu-latest
container:
image: antonengelhardt/rust-docker-tools
image: ghcr.io/antonengelhardt/rust-docker-tools
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -77,6 +142,8 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Rust version
run: rustc --version && cargo --version
Expand All @@ -88,7 +155,7 @@ jobs:
runs-on: ubuntu-latest
container:
image: ghcr.io/antonengelhardt/rust-docker-tools
needs: [cargo-deny, clippy, fmt, test]
needs: [verify-project]

steps:
- name: Checkout code
Expand All @@ -104,10 +171,12 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

- name: Build wasm-oidc-plugin
run: |
cargo build --target wasm32-wasi --release
cargo build --target wasm32-wasip1 --release

- name: Upload plugin as artifact
uses: actions/upload-artifact@v4
Expand All @@ -116,7 +185,7 @@ jobs:
path: target/wasm32-wasi/release/wasm_oidc_plugin.wasm

docker-image:
needs: [cargo-deny, clippy, fmt, test]
needs: [verify-project]
runs-on: ubuntu-latest

steps:
Expand All @@ -141,7 +210,7 @@ jobs:

ghcr-image:
runs-on: ubuntu-latest
needs: [cargo-deny, clippy, fmt, test]
needs: [verify-project]
permissions:
contents: read
packages: write
Expand Down
Loading
Loading