Skip to content

feat: introspection_endpoint #256

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

Merged
merged 5 commits into from
May 16, 2022
Merged

feat: introspection_endpoint #256

merged 5 commits into from
May 16, 2022

Conversation

ybelMekk
Copy link
Contributor

No description provided.

@ybelMekk ybelMekk requested a review from a team as a code owner May 12, 2022 22:03
@ybelMekk ybelMekk added the enhancement New feature or request label May 12, 2022
@ybelMekk ybelMekk linked an issue May 12, 2022 that may be closed by this pull request
@ybelMekk ybelMekk requested review from tommytroen and tronghn May 13, 2022 12:58
@patcon
Copy link

patcon commented May 14, 2022

Ahhhhh you're the best...! Ok, I'm a little out of my element, but I'll try to sort out how to build and test this.

I expect the approach I'd take is to create a Dockerfile for a container for building feature branches, and then I could upstream that for others like me who wish to try a build from an unpublished feature branch, but don't know much about java.

Does that sound like an OK approach? I'm seeing that you use something called "jib" to build the existing containers (which doesn't use a docker daemon?) and so it seems I'm going a little off-road, but wondering: would this still be useful as a sample Dockerfile support file I could upstream? Also, I'm open to suggestions for other ways to make a feature branch available in a docker-compose.yml file, like you've generously documented in the README for official releases

@patcon
Copy link

patcon commented May 14, 2022

To be clear, this is how I'm thinking I'd aim to get things to work:

version: '3.7'
services:
  your_app:
    build: .
    ports:
      - 8080:8080
  mock-oauth2-server:
    # Not using this.
    #image: ghcr.io/navikt/mock-oauth2-server:$MOCK_OAUTH2_SERVER_VERSION
    # And instead using this (with example file that might also become available upstream?)
    build: ./support/mock-auth.Dockerfile
    environment:
      MOCK_AUTH_REPO_SLUG: navikt/mock-oauth2-server
      MOCK_AUTH_REPO_BRANCH: introspection_endpoint
    ports:
      - 8080:8080
    hostname: host.docker.internal

@ybelMekk
Copy link
Contributor Author

ybelMekk commented May 14, 2022

@patcon

a bit hakky but;

by comment this out in build.gradle.kts

           // platform {
           //     architecture = "arm64"
           //     os = "linux"
           // }

You can run gradle jibDockerBuild to build a snapshot to run locally.

@patcon
Copy link

patcon commented May 15, 2022

I don't yet have a simple way to have the whole team using it (since we rely on docker and our dev environment doesn't support building java projects for everyone easily), but I've built it locally and it works for me!

@ybelMekk
Copy link
Contributor Author

@tommytroen 🚤?

* removed unnecessary null check on form parameters
* changed data type for exp, iat, nbf to long
@tommytroen
Copy link
Collaborator

@ybelMekk Looks good! Added a few minor changes.

@ybelMekk ybelMekk changed the title wip: add introspection_endpoint feat: introspection_endpoint May 16, 2022
@ybelMekk ybelMekk merged commit 5417d4e into master May 16, 2022
@ybelMekk ybelMekk deleted the introspection_endpoint branch May 16, 2022 07:47
@patcon
Copy link

patcon commented May 16, 2022

Thanks so so much @tommytroen and @ybelMekk 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support mocked introspect endpoint
3 participants