{"id":13455180,"url":"https://github.com/mtlynch/picoshare","last_synced_at":"2025-05-13T17:13:33.629Z","repository":{"id":38009655,"uuid":"458991305","full_name":"mtlynch/picoshare","owner":"mtlynch","description":"A minimalist, easy-to-host service for sharing images and other files","archived":false,"fork":false,"pushed_at":"2025-04-29T08:39:00.000Z","size":6996,"stargazers_count":2518,"open_issues_count":30,"forks_count":179,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-05-13T09:05:26.869Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://demo.pico.rocks","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mtlynch.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","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,"zenodo":null}},"created_at":"2022-02-14T02:33:38.000Z","updated_at":"2025-05-13T05:54:53.000Z","dependencies_parsed_at":"2023-09-29T03:37:52.095Z","dependency_job_id":"f29b334d-acb0-482d-9371-4b2887932326","html_url":"https://github.com/mtlynch/picoshare","commit_stats":{"total_commits":440,"total_committers":12,"mean_commits":"36.666666666666664","dds":0.04318181818181821,"last_synced_commit":"32e34045f4fed32b2e7c32c3e0aaa7bd3178151e"},"previous_names":[],"tags_count":45,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mtlynch%2Fpicoshare","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mtlynch%2Fpicoshare/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mtlynch%2Fpicoshare/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mtlynch%2Fpicoshare/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mtlynch","download_url":"https://codeload.github.com/mtlynch/picoshare/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253990492,"owners_count":21995776,"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":[],"created_at":"2024-07-31T08:01:02.155Z","updated_at":"2025-05-13T17:13:28.617Z","avatar_url":"https://github.com/mtlynch.png","language":"Go","funding_links":[],"categories":["Go","Apps","Sync-Tools","Software"],"sub_categories":["FileSharing","File Transfer - Single-click \u0026 Drag-n-drop Upload"],"readme":"# PicoShare\n\n[![CircleCI](https://circleci.com/gh/mtlynch/picoshare.svg?style=svg)](https://circleci.com/gh/mtlynch/picoshare)\n[![Docker Version](https://img.shields.io/docker/v/mtlynch/picoshare?sort=semver\u0026maxAge=86400)](https://hub.docker.com/r/mtlynch/picoshare/)\n[![Docker Pulls](https://img.shields.io/docker/pulls/mtlynch/picoshare.svg?maxAge=604800)](https://hub.docker.com/r/mtlynch/picoshare/)\n[![GitHub commit activity](https://img.shields.io/github/commit-activity/m/mtlynch/picoshare)](https://github.com/mtlynch/picoshare/commits/master)\n[![GitHub last commit](https://img.shields.io/github/last-commit/mtlynch/picoshare)](https://github.com/mtlynch/picoshare/commits/master)\n[![Contributors](https://img.shields.io/github/contributors/mtlynch/picoshare)](https://github.com/mtlynch/picoshare/graphs/contributors)\n[![License](http://img.shields.io/:license-agpl-blue.svg?style=flat-square)](LICENSE)\n\n## Overview\n\nPicoShare is a minimalist service that allows you to share files easily.\n\n- [Live demo](https://demo.pico.rocks)\n\n[![PicoShare demo](https://raw.githubusercontent.com/mtlynch/picoshare/master/docs/readme-assets/demo.gif)](https://raw.githubusercontent.com/mtlynch/picoshare/master/docs/readme-assets/demo-full.gif)\n\n## Why PicoShare?\n\nThere are a million services for sharing files, but none of them are quite like PicoShare. Here are PicoShare's advantages:\n\n- **Direct download links**: PicoShare gives you a direct download link you can share with anyone. They can view or download the file with no ads or signups.\n- **No file restrictions**: Unlike sites like imgur, Vimeo, or SoundCloud that only allow you to share specific types of files, PicoShare lets you share any file of any size.\n- **No resizing/re-encoding**: If you upload media like images, video, or audio, PicoShare never forces you to wait on re-encoding. You get a direct download link as soon as you upload the file, and PicoShare never resizes or re-encodes your file.\n\n## Run PicoShare\n\n### From source\n\n```bash\nPS_SHARED_SECRET=somesecretpass PORT=4001 \\\n  go run cmd/picoshare/main.go\n```\n\n### From Docker\n\nTo run PicoShare within a Docker container, mount a volume from your local system to store the PicoShare sqlite database.\n\n```bash\ndocker run \\\n  --env \"PORT=4001\" \\\n  --env \"PS_SHARED_SECRET=somesecretpass\" \\\n  --publish 4001:4001/tcp \\\n  --volume \"${PWD}/data:/data\" \\\n  --name picoshare \\\n  mtlynch/picoshare\n```\n\n### From Docker + cloud data replication\n\nIf you specify settings for a [Litestream](https://litestream.io/)-compatible cloud storage location, PicoShare will automatically replicate your data.\n\nYou can kill the container and start it later, and PicoShare will restore your data from the cloud storage location and continue as if there was no interruption.\n\n```bash\nPORT=4001\nPS_SHARED_SECRET=\"somesecretpass\"\nLITESTREAM_BUCKET=YOUR-LITESTREAM-BUCKET\nLITESTREAM_ENDPOINT=YOUR-LITESTREAM-ENDPOINT\nLITESTREAM_ACCESS_KEY_ID=YOUR-ACCESS-ID\nLITESTREAM_SECRET_ACCESS_KEY=YOUR-SECRET-ACCESS-KEY\n\ndocker run \\\n  --publish \"${PORT}:${PORT}/tcp\" \\\n  --env \"PORT=${PORT}\" \\\n  --env \"PS_SHARED_SECRET=${PS_SHARED_SECRET}\" \\\n  --env \"LITESTREAM_ACCESS_KEY_ID=${LITESTREAM_ACCESS_KEY_ID}\" \\\n  --env \"LITESTREAM_SECRET_ACCESS_KEY=${LITESTREAM_SECRET_ACCESS_KEY}\" \\\n  --env \"LITESTREAM_BUCKET=${LITESTREAM_BUCKET}\" \\\n  --env \"LITESTREAM_ENDPOINT=${LITESTREAM_ENDPOINT}\" \\\n  --name picoshare \\\n  mtlynch/picoshare\n```\n\nNotes:\n\n- Only run one Docker container for each Litestream location.\n  - PicoShare can't sync writes across multiple instances.\n\n### Using Docker Compose\n\nTo run PicoShare under docker-compose, copy the following to a file called `docker-compose.yml` and then run `docker-compose up`.\n\n```yaml\nversion: \"3.2\"\nservices:\n  picoshare:\n    image: mtlynch/picoshare\n    environment:\n      - PORT=4001\n      - PS_SHARED_SECRET=dummypass # Change to any password\n    ports:\n      - 4001:4001\n    command: -db /data/store.db\n    volumes:\n      - ./data:/data\n```\n\n## Parameters\n\n### Command-line flags\n\n| Flag  | Meaning                 | Default Value     |\n| ----- | ----------------------- | ----------------- |\n| `-db` | Path to SQLite database | `\"data/store.db\"` |\n\n### Environment variables\n\n| Environment Variable | Meaning                                                                              |\n| -------------------- | ------------------------------------------------------------------------------------ |\n| `PORT`               | TCP port on which to listen for HTTP connections (defaults to 4001).                 |\n| `PS_BEHIND_PROXY`    | Set to `\"true\"` for better logging when PicoShare is running behind a reverse proxy. |\n| `PS_SHARED_SECRET`   | (required) Specifies a passphrase for the admin user to log in to PicoShare.         |\n\n### Docker environment variables\n\nYou can adjust behavior of the Docker container by specifying these Docker-specific variables with `docker run -e`:\n\n| Environment Variable           | Meaning                                                                                               |\n| ------------------------------ | ----------------------------------------------------------------------------------------------------- |\n| `LITESTREAM_BUCKET`            | Litestream-compatible cloud storage bucket where Litestream should replicate data.                    |\n| `LITESTREAM_ENDPOINT`          | Litestream-compatible cloud storage endpoint where Litestream should replicate data.                  |\n| `LITESTREAM_ACCESS_KEY_ID`     | Litestream-compatible cloud storage access key ID to the bucket where you want to replicate data.     |\n| `LITESTREAM_SECRET_ACCESS_KEY` | Litestream-compatible cloud storage secret access key to the bucket where you want to replicate data. |\n| `LITESTREAM_RETENTION`         | The amount of time Litestream snapshots \u0026 WAL files will be kept (defaults to 72h).                   |\n\n### Docker build args\n\nIf you rebuild the Docker image from source, you can adjust the build behavior with `docker build --build-arg`:\n\n| Build Arg            | Meaning                                                                     | Default Value |\n| -------------------- | --------------------------------------------------------------------------- | ------------- |\n| `litestream_version` | Version of [Litestream](https://litestream.io/) to use for data replication | `0.3.9`       |\n\n## PicoShare's scope and future\n\nPicoShare is maintained by Michael Lynch as a hobby project.\n\nDue to time limitations, I keep PicoShare's scope limited to only the features that fit into my workflows. That unfortunately means that I sometimes reject proposals or contributions for perfectly good features. It's nothing against those features, but I only have bandwidth to maintain features that I use.\n\n## Deployment\n\nPicoShare is easy to deploy to cloud hosting platforms:\n\n- [fly.io](docs/deployment/fly.io.md)\n\n## Tips and tricks\n\n### Reclaiming reserved database space\n\nSome users find it surprising that when they delete files from PicoShare, they don't gain back free space on their filesystem.\n\nWhen you delete files, PicoShare reserves the space for future uploads. If you'd like to reduce PicoShare's usage of your filesystem, you can manually force PicoShare to give up the space by performing the following steps:\n\n1. Shut down PicoShare.\n1. Run `sqlite3 data/store.db 'VACUUM'` where `data/store.db` is the path to your PicoShare database.\n\nYou should find that the `data/store.db` should shrink in file size, as it relinquishes the space dedicated to previously deleted files. If you start PicoShare again, the System Information screen will show the smaller size of PicoShare files.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmtlynch%2Fpicoshare","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmtlynch%2Fpicoshare","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmtlynch%2Fpicoshare/lists"}