{"id":15287225,"url":"https://github.com/lukasbecvar/code-paste","last_synced_at":"2026-05-08T13:46:49.840Z","repository":{"id":256393939,"uuid":"855154937","full_name":"lukasbecvar/code-paste","owner":"lukasbecvar","description":"Free webapp service for storing and sharing text and code snippets","archived":false,"fork":false,"pushed_at":"2025-02-06T07:43:27.000Z","size":259,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-06T08:34:36.125Z","etag":null,"topics":["mysql","paste","pastebin","php","snippets","symfony"],"latest_commit_sha":null,"homepage":"https://paste.becvar.xyz/","language":"PHP","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/lukasbecvar.png","metadata":{"files":{"readme":"README.MD","changelog":null,"contributing":null,"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}},"created_at":"2024-09-10T12:05:33.000Z","updated_at":"2025-02-06T07:40:12.000Z","dependencies_parsed_at":"2024-09-10T13:45:51.338Z","dependency_job_id":"3747fc49-09e8-4b47-b4da-ce029f79c869","html_url":"https://github.com/lukasbecvar/code-paste","commit_stats":null,"previous_names":["lordbecvold/code-paste","lukasbecvar/code-paste"],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasbecvar%2Fcode-paste","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasbecvar%2Fcode-paste/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasbecvar%2Fcode-paste/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukasbecvar%2Fcode-paste/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lukasbecvar","download_url":"https://codeload.github.com/lukasbecvar/code-paste/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245200679,"owners_count":20576673,"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":["mysql","paste","pastebin","php","snippets","symfony"],"created_at":"2024-09-30T15:26:47.632Z","updated_at":"2026-05-08T13:46:49.829Z","avatar_url":"https://github.com/lukasbecvar.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Code paste\nSelf-hosted solution for sharing text and code snippets.\n\n## Preview\n![Paste view](.github/images/preview.png)\n\n## Features\n- Share text and code snippets\n- Paste content encryption\n- SSL only mode\n- Maintenance mode\n- Syntax highlighting\n\n## Installation - Development\n1. Clone the repository\n2. Run with docker compose (scripts/docker-start-dev.sh)\n3. Load testing database fixtures (scripts/load-fixtures.sh)\n\n## Installation - Production\n1. Clone this repository\n2. Install dependencies ``npm install \u0026\u0026 composer install``\n3. Build assets ``npm run build``\n4. Create database ``php bin/console doctrine:database:create --if-not-exists``\n5. Migrate database ``php bin/console doctrine:migrations:migrate --no-interaction``\n6. Configure website host [apache-site.conf](./docker/configs/apache-site.conf)\n\n## Installation - Docker\nYou can build a docker image using the production docker file or use the image available here in github packages.\n```yaml\nphp:\n    image: ghcr.io/lukasbecvar/code-paste:latest\n    container_name: code_paste_webserver\n    restart: always\n    depends_on:\n        - mysql\n    environment:\n        - DATABASE_HOST=127.0.0.1\n        - DATABASE_PORT=3306\n        - DATABASE_NAME=code_paste\n        - DATABASE_USERNAME=root\n        - DATABASE_PASSWORD=root\n        ...\n    volumes:\n        - ./.docker/services/log:/var/log\n    mem_limit: 1g\n    ports:\n        - \"80:80\"\n    networks:\n        - main\n```\n\n## Configuration\n1. Create your own .env file with name .env.prod and change app env in main .env\n2. Configure SSL_ONLY false or true if you want allow only SSL traffic\n3. Configure MAINTENANCE_MODE true or false if you want to enable maintenance mode\n4. ENCRYPTION_MODE true or false if you want to enable paste content encryption (key is APP_SECRET value in .env)\n5. Configure DATABASE_DRIVER, DATABASE_HOST, DATABASE_PORT, DATABASE_NAME, DATABASE_USERNAME, DATABASE_PASSWORD\n#### Environment variables\nThe environment variables are loaded from .env file. You can create .env file in root directory with your configuration.\n| Variable | Description | Example value |\n| --- | --- | --- |\n| APP_SECRET | Secret key for application security (used for hashing, encryption, etc.) | 6514635062ba34f218535f9f106fd20b |\n| SSL_ONLY | Allow access only via HTTPS protocol | false |\n| MAINTENANCE_MODE | Enable or disable maintenance mode | false |\n| ENCRYPTION_MODE | Enable encryption for pasted content | true |\n| CONTACT_EMAIL | Administrator contact email | lukas@becvar.xyz |\n| EXTERNAL_LOG_ENABLED | Enable external log sending | false |\n| EXTERNAL_LOG_URL | External log API endpoint | https://admin.becvar.xyz/api/external/log |\n| EXTERNAL_LOG_TOKEN | Authentication token for external log API | cbd8b08271wefg |\n| METRICS_EXPORTER_ENABLED | Enable metrics exporter | true |\n| METRICS_EXPORTER_ALLOWED_IP | IP address allowed to access metrics (`%` = all) | % |\n| VISITOR_TRACKING_ENABLED | Enable visitor tracking | false |\n| VISITOR_TRACKING_SERVICE_NAME | Service name for visitor tracking | paste.becvar.xyz |\n| VISITOR_TRACKING_URL | API endpoint for visitor tracking | https://admin.becvar.xyz/api/monitoring/visitor/tracking |\n| DATABASE_DRIVER | Database driver type | pdo_mysql |\n| DATABASE_VERSION | Database version | 8.0.43 |\n| DATABASE_HOST | Database host address | 127.0.0.1 |\n| DATABASE_PORT | Database port | 3306 |\n| DATABASE_NAME | Database name | code_paste |\n| DATABASE_USERNAME | Database username | root |\n| DATABASE_PASSWORD | Database password | root |\n\n## Requirements\n- Apache or Nginx web server with PHP support\n- NodeJS with npm\n- Composer\n- PHP 8.5\n- MySQL\n\n## License\nThis software is licensed under the [MIT license](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukasbecvar%2Fcode-paste","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flukasbecvar%2Fcode-paste","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukasbecvar%2Fcode-paste/lists"}