{"id":20205708,"url":"https://github.com/floriankarsten/simple-staging","last_synced_at":"2025-10-25T08:38:56.075Z","repository":{"id":62505806,"uuid":"357136560","full_name":"floriankarsten/simple-staging","owner":"floriankarsten","description":"Kirby Janitor job for staging","archived":false,"fork":false,"pushed_at":"2023-04-27T13:30:18.000Z","size":22,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-05T03:55:45.124Z","etag":null,"topics":["kirby","kirby-cms","kirby-plugin","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/floriankarsten.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}},"created_at":"2021-04-12T09:37:56.000Z","updated_at":"2024-11-28T10:56:11.000Z","dependencies_parsed_at":"2022-11-02T10:02:11.341Z","dependency_job_id":null,"html_url":"https://github.com/floriankarsten/simple-staging","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floriankarsten%2Fsimple-staging","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floriankarsten%2Fsimple-staging/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floriankarsten%2Fsimple-staging/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/floriankarsten%2Fsimple-staging/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/floriankarsten","download_url":"https://codeload.github.com/floriankarsten/simple-staging/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248217081,"owners_count":21066633,"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":["kirby","kirby-cms","kirby-plugin","php"],"created_at":"2024-11-14T05:18:46.417Z","updated_at":"2025-10-25T08:38:55.992Z","avatar_url":"https://github.com/floriankarsten.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Simple staging Janitor jobs\nPlugin for very simple staging setup for https://github.com/bnomei/kirby3-janitor/ (required). Beta quality - use at your own risk. It's working without problems for me but any comments and suggestions for improvements are welcome.\nThere are two variants pure php and rsync.\n\n## Requirements\nPlugin assumes flat structure and while you can define the destination (live site) as you want i would suggest structure like\n```\nwebsites/\n\tstaging.mysite.com\n\tmysite.com\n```\n## PHP job vs Rsync job\nBoth jobs are different.\nThe *PHP job* should be more compatible but it naive, takes longer, it alwyas copies everything and it requires you to have space for 3 versions of your site. It works like this\n1. Copy staging.mysite.com to __staging_mysite.com\n2. Rename mysite.com to __tobedeleted_mysite.com\n3. Rename __staging_mysite.com to mysite.com\n4. Delete __tobedeleted_mysite.com\n\n*Rsync job* requires you to have rsync available on your server but it syncs changes from staging to live directly. This makes it much more efficient and you have only 2 versions of site at the time. Rsync also has better include/exclude options. Many shared hostings with ssh have rsync available but check if you allow php to run exec();.\n\nYou probably want to use *Rsync job* if you can.\n\n## Install\n```composer require floriankarsten/simple-staging```\n\nconfig.php\n```php\n// Required loads the jobs\n'bnomei.janitor.jobs-extends' =\u003e [\n\t'floriankarsten.simplestaging.jobs'\n],\n// this is required name of final destination of website\n// for example if i have site folders staging.test.com and test.com i set test.com as destination\n'floriankarsten.simplestaging' =\u003e [\n\t'destination' =\u003e 'test.com',\n\t'base' =\u003e '/users/floriankarsten/bestwebsite/' // Not required. Absolute path to base of our website. By default its parent of index/public folder which is what you probably want.\n]\n```\n\nIn your blueprint\n```yaml\n// PHP job\npushlive:\n  type: janitor\n  label: Deploy to Live site rsync\n  progress: Deploying...\n  job: deploylive\n\n// Rsync job\npushlive:\n  type: janitor\n  label: Deploy to Live site rsync\n  progress: Deploying...\n  job: deployliversync\n```\n\n\n## Configuration PHP job\n```php\n'floriankarsten.simplestaging' =\u003e [\n\t'basic' =\u003e [ // 'basic' is namespace for our 'php job'\n\t\t'excludedir' =\u003e ['vendor', 'node_modules'] // basic job can only exclude directories. Empty by default.\n\t],\n]\n```\n\n## Configuration Rsync job\n```php\n'floriankarsten.simplestaging' =\u003e [\n\t'rsync' =\u003e [\n\t\t'executable' =\u003e '/usr/lib/rsync' // path to rsync library. Default 'rsync'\n\t\t'flags' =\u003e ['a', 'r'] // overwrite default rsync flags. Default ['a', 'r']\n\t\t// include/exclude work as if they were passed directly to rsync (so things like *.jpg etc.). If you use only include without exclude we assume and exclude '*'\n\t\t'exclude' =\u003e ['vendor', 'node_modules'], // Empty by default.\n\t\t'include' =\u003e ['content'], // Empty by default.\n\t],\n]\n```\n\n\n\n\nThis plugin wouldn't happen without [@garethworld](https://github.com/garethworld) who kindly hired me to make it and then wanted to have it released to Kirby community. Thanks GARETH\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloriankarsten%2Fsimple-staging","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffloriankarsten%2Fsimple-staging","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloriankarsten%2Fsimple-staging/lists"}