Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/samkhawase/authzero
AuthZero integration with Postgrest
https://github.com/samkhawase/authzero
auth auth0 postgresql postgrest rest-api sql
Last synced: 20 days ago
JSON representation
AuthZero integration with Postgrest
- Host: GitHub
- URL: https://github.com/samkhawase/authzero
- Owner: samkhawase
- Created: 2020-02-27T14:11:24.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-06-09T20:47:21.000Z (over 4 years ago)
- Last Synced: 2024-11-18T07:20:46.365Z (3 months ago)
- Topics: auth, auth0, postgresql, postgrest, rest-api, sql
- Language: Swift
- Size: 16.6 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# AuthZero
AuthZero integration with Postgrest.This is part of the [blog series](https://samkhawase.com/blog/postgrest) about PostgREST API tutorial, and it's integration with Auth0.
## Getting Started
Here are the steps to get started with the project on your local machine:
1. Clone the git repositiory
2. Run `carthage update --platform iOS --cache-builds --no-use-binaries` to fetch the dependencies.
3. Run the project via Xcode.### Prerequisites
What things you need to install the software and how to install them
1. Mac OS X
2. Xcode 9
3. [Carthage](https://github.com/Carthage/Carthage)
4. Optional: [xcpretty](https://github.com/supermarin/xcpretty)## Auth0 Integration
Add the _Client ID_ and _Domain name_ in the `Auth0.plist` of the iOS app. You can find these values in the Auth0 Dashboard.## Building the app
To build the app, enter the command on the command line.
```
xcodebuild -scheme 'AuthZero' \ 3744ms Wed Mar 18 16:10:48 2020
-sdk iphonesimulator \
-configuration Debug \
-destination 'platform=iOS Simulator,name=iPhone 8,OS=latest' \
clean build | xcpretty
```The output will be similar to:
```
▸ Clean Succeeded
▸ Compiling ViewController.swift⚠️ ~/AuthZero/AuthZero/ViewController.swift:51:17: immutable value 'roles' was never used; consider replacing with '_' or removing it
let roles = jwt.claim(name: "https://postgrest-demo.de/role").array
^~~~~
▸ Compiling AppDelegate.swift
▸ Compiling SceneDelegate.swift
▸ Linking AuthZero
▸ Copying Auth0.plist
▸ Compiling Main.storyboard
▸ Compiling LaunchScreen.storyboard
▸ Processing Info.plist
▸ Running script 'Run Script'
▸ Touching AuthZero.app (in target 'AuthZero' from project 'AuthZero')
▸ Build Succeeded
```## License
This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details