{"id":50205262,"url":"https://github.com/eliottwantz/plock","last_synced_at":"2026-05-26T01:03:56.490Z","repository":{"id":245026264,"uuid":"815238690","full_name":"eliottwantz/plock","owner":"eliottwantz","description":"Plock is an all in one authentication server, providing email \u0026 password, email verification codes, two-factor authentication, OAuth with social providers, and passkey authentication.","archived":false,"fork":false,"pushed_at":"2024-07-31T15:45:34.000Z","size":1410,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-05-01T04:26:36.279Z","etag":null,"topics":["authentication","bearer-tokens","docker","javascript","mobile-authentication","oauth2","passkeys","sessions","sveltekit","tailwindcss","turso","typescript"],"latest_commit_sha":null,"homepage":"https://develiott.com/projects/plock","language":"Svelte","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eliottwantz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-14T16:50:27.000Z","updated_at":"2024-07-31T15:45:39.000Z","dependencies_parsed_at":"2024-06-19T05:10:09.794Z","dependency_job_id":"6f32563a-0a14-4acd-809d-3762f6229f4d","html_url":"https://github.com/eliottwantz/plock","commit_stats":null,"previous_names":["eliottwantz/plock"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eliottwantz/plock","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliottwantz%2Fplock","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliottwantz%2Fplock/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliottwantz%2Fplock/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliottwantz%2Fplock/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eliottwantz","download_url":"https://codeload.github.com/eliottwantz/plock/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliottwantz%2Fplock/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33499282,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-25T14:31:05.219Z","status":"ssl_error","status_checked_at":"2026-05-25T14:31:02.878Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["authentication","bearer-tokens","docker","javascript","mobile-authentication","oauth2","passkeys","sessions","sveltekit","tailwindcss","turso","typescript"],"created_at":"2026-05-26T01:03:53.675Z","updated_at":"2026-05-26T01:03:56.481Z","avatar_url":"https://github.com/eliottwantz.png","language":"Svelte","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Plock\n\nPlock is an all-in-one authentication server, providing email \u0026 password, email verification codes, two-factor authentication, OAuth with social providers, and passkey authentication, with session management using cookies and bearer tokens.\n\n\u003e [!WARNING]\n\u003e N.B. This project is still in early development. It is not ready for production use yet.\n\u003e It currently only supports `Turso` and `Postgres` as the database. I am gradually adding support for other databases, such as SQLite and MySQL.\n\n\u003cbr /\u003e\n\u003cimg src=\"./.github/plockdemo.gif\" /\u003e\n\n## Table of content\n\n- [Plock](#Plock)\n  - [Table of content](#table-of-content)\n- [Usage](#usage)\n- [Environment variables](#environment-variables)\n  - [General environment](#general-environment)\n  - [Database environment](#database-environment)\n    - [Turso/LibSQL](#turso-libSQL)\n    - [Postgres](#postgresql)\n\n## Usage\n\nSimply pull the Docker image and use it with your app:\n\n```bash\ndocker pull ghcr.io/eliottwantz/plock:latest\ndocker run -it --rm -p 5173:5173 ghcr.io/eliottwantz/plock:latest\n```\n\nor with docker-compose:\n\n```yaml\nservices:\n  plock:\n    image: ghcr.io/eliottwantz/plock:latest\n    ports:\n      - 5173:5173\n    env_file:\n      - .env\n```\n\n## Environment variables\n\n### General environment\n\nPlease check an example of the .env file in the example [examples/simple](./examples/simple/.env.example)\n\n| Name                       | Description                                                            |\n| -------------------------- | ---------------------------------------------------------------------- |\n| `PORT`                     | The port to listen on. Defaults to 5173.                               |\n| `ENV`                      | The environment to run in, either `DEV` or `PROD`                      |\n| `GOOGLE_CLIENT_ID`         | The client ID of the Google OAuth provider.                            |\n| `GOOGLE_CLIENT_SECRET`     | The client secret of the Google OAuth provider.                        |\n| `GOOGLE_AUTH_CALLBACK_URL` | The callback URL of the Google OAuth provider.                         |\n| `GITHUB_CLIENT_ID`         | The client ID of the GitHub OAuth provider.                            |\n| `GITHUB_CLIENT_SECRET`     | The client secret of the GitHub OAuth provider.                        |\n| `PUBLIC_AUTH_ORIGIN`       | The origin of the Plock server.                                        |\n| `PUBLIC_CALLBACK_URL`      | The callback URL where you want to be redirected after authentication. |\n| `PUBLIC_LOGOUT_URL`        | The URL where you want to be redirected after logout.                  |\n| `PUBLIC_SITE_NAME`         | The name of your website.                                              |\n\n### Database environment\n\nDepending on the DB that you are using, set these environment variables accordingly:\n\n\u003e [!TIP]\n\u003e Use `host.docker.internal` instead of `localhost` for the DB host.\n\n#### Turso / LibSQL\n\n| Name            | Description                                                                  |\n| --------------- | ---------------------------------------------------------------------------- |\n| `DB_TYPE`       | The database type. Must be `turso`.                                          |\n| `DB_URL`        | The URL of the turso server. Defaults to `http://host.docker.internal:8080`. |\n| `DB_AUTH_TOKEN` | The token of the turso server. Defaults to `null`.                           |\n\n#### PostgreSQL\n\n| Name      | Description                                                                                                   |\n| --------- | ------------------------------------------------------------------------------------------------------------- |\n| `DB_TYPE` | The database type. Must be `postgres`.                                                                        |\n| `DB_URL`  | The Postgres connection URL. Defaults to `postgresql://postgres:postgres@host.docker.internal:5432/postgres`. |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feliottwantz%2Fplock","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feliottwantz%2Fplock","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feliottwantz%2Fplock/lists"}