{"id":14155129,"url":"https://github.com/stophecom/sharrr-svelte","last_synced_at":"2025-04-05T21:09:44.786Z","repository":{"id":150135083,"uuid":"590601512","full_name":"stophecom/sharrr-svelte","owner":"stophecom","description":"End-to-end encrypted file transfer.","archived":false,"fork":false,"pushed_at":"2024-10-24T18:35:51.000Z","size":3003,"stargazers_count":120,"open_issues_count":7,"forks_count":4,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-10-24T21:33:02.070Z","etag":null,"topics":["cryptography","e2ee","file-transfer","file-upload","svelte","tailwindcss","web","webcrypto"],"latest_commit_sha":null,"homepage":"https://www.sharrr.com","language":"Svelte","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stophecom.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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":"2023-01-18T19:32:31.000Z","updated_at":"2024-10-22T12:17:02.000Z","dependencies_parsed_at":"2023-09-26T22:47:35.968Z","dependency_job_id":"c2cf29ec-752d-4920-ac31-d6be918d296c","html_url":"https://github.com/stophecom/sharrr-svelte","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stophecom%2Fsharrr-svelte","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stophecom%2Fsharrr-svelte/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stophecom%2Fsharrr-svelte/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stophecom%2Fsharrr-svelte/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stophecom","download_url":"https://codeload.github.com/stophecom/sharrr-svelte/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247399879,"owners_count":20932880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["cryptography","e2ee","file-transfer","file-upload","svelte","tailwindcss","web","webcrypto"],"created_at":"2024-08-17T08:02:11.012Z","updated_at":"2025-04-05T21:09:44.770Z","avatar_url":"https://github.com/stophecom.png","language":"Svelte","funding_links":[],"categories":["web"],"sub_categories":[],"readme":"# sharrr\n\n**One-time end-to-end encrypted file transfer.**\n\nTransfer files (of virtually unlimited size) asynchronously and in the most secure way possible.\n\nLearn more about the [technical implementation](https://sharrr.com/about). See how [sharrr compares](https://github.com/stophecom/sharrr-svelte/blob/main/src/routes/about/comparison.md) to other services.\n\nWebsite: [www.sharrr.com](https://sharrr.com)\n\nHelp keep this project running: [Make a donation](https://donate.stripe.com/28oeV1gKP3bv4b6144)\n\n## Developing\n\nBefore you start, add an `.env` file at the root of the project. See below.\n\n```bash\n# Initial installation\npnpm i\n\n# Run dev server\npnpm run dev\n\n# or start the server and open the app in a new browser tab\npnpm run dev -- --open\n```\n\n### DB\n\n#### Prisma ORM\n\n```bash\n# Init primsa\nnpx prisma init\n\n# Push schema to Postgres\nnpx prisma db push\n\n# Open prisma studio locally\nnpx prisma studio\n\n# After changes in DB are made. Should not be necessary.\n# https://www.prisma.io/docs/concepts/components/prisma-client#4-evolving-your-application\nnpx prisma generate\n```\n\n#### Postgres Database\n\nUsing Vercel Postgres Database currently, but can be done with any Prisma compatible database.\n\n### Tests\n\n```bash\n# Run unit tests with vitest\n# Important: Node 19+ is required (Support for crypto modules)\npnpm run test:unit\n\n\n# E2E tests with playwright\npnpm run test\n\n```\n\n### Building\n\nTo create a production version of your app:\n\n```bash\npnpm run build\n```\n\nYou can preview the production build with `pnpm run preview`.\n\n### Maintenance\n\nThere is a Github workflow `cron-cleanup-files.yml` that runs every day to cleanup old files.\nSee `src/routes/api/v1/cron/+server.ts` for more info.\n\nYou can trigger the cron job locally with:\n\n```bash\ncurl --request POST \\\n     --url 'http://localhost:3000/api/v1/cron' \\\n     --header 'Authorization: Bearer API_SECRET_KEY'\n\n```\n\n## Self hosting\n\n\u003e **Note**\n\u003e The project currently runs un Vercel, uses S3 for storage and Vercel Postgres DB. Self-hosting requires you to replace those 3rd party solutions.\n\n### Current setup\n\n#### ENV Variables\n\n```bash\n# Postgres\nPOSTGRES_PRISMA_URL='postgres://'\nPOSTGRES_URL_NON_POOLING='postgres://' # Direct Connection\n\n# S3 compatible object storage e.g. AWS\nS3_ENDPOINT='\u003cstring\u003e'\nS3_ACCESS_KEY='\u003cstring\u003e'\nS3_SECRET_KEY='\u003cstring\u003e'\nPUBLIC_S3_BUCKET='\u003cstring\u003e'\n\n# Vercel specific, but can be easily replaced.\nVERCEL_URL='http://localhost:3000'\nPUBLIC_ENV='development' # preview/production\n\n# Only used for cron jobs that run using Github Actions.\nAPI_SECRET_KEY='\u003cstring\u003e'\n```\n\n### With Docker (WIP)\n\nYou'll need to edit the environment variables within the `.env` file.\n\n\u003e **Note**\n\u003e To run the app in Docker you still need to connect your own DB. Same goes if you want to run your own S3 storage solution. This part is not covered yet.\n\nOnce you've done that, you can do the following:\n\n```bash\n# to start the docker container\nsudo docker compose up -d\n\n# to stop the docker container\nsudo docker compose down\n\n# to check logs\nsudo docker logs sharrr\n```\n\n## About\n\nAbout the author: [stophe.com](https://stophe.com)\n\n### Stack\n\n- SvelteKit\n- Tailwind CSS\n- PostgreSQL (Database)\n- Prisma (ORM)\n- Doppler (For env handling)\n\nThis project is tested with BrowserStack.\n\n### Infrastructure\n\n- Website and Postgres on [Vercel](https://vercel.com/)\n- S3 Object Storage with [flow.swiss](https://flow.swiss)\n\n### License\n\n[MIT](https://opensource.org/license/mit/) (Code)\n\n[CC BY-NC-ND](https://creativecommons.org/licenses/by-nc-nd/4.0/) (Creatives)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstophecom%2Fsharrr-svelte","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstophecom%2Fsharrr-svelte","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstophecom%2Fsharrr-svelte/lists"}