PHPackages                             sonntagnacht/deploy-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [DevOps &amp; Deployment](/categories/devops)
4. /
5. sonntagnacht/deploy-bundle

ActiveSymfony-bundle[DevOps &amp; Deployment](/categories/devops)

sonntagnacht/deploy-bundle
==========================

command to deploy your project for symfony 2.8+

1.0.5(7y ago)31652MITPHPPHP &gt;=5.6

Since Feb 4Pushed 7y ago2 watchersCompare

[ Source](https://github.com/sonntagnacht/SNDeployBundle)[ Packagist](https://packagist.org/packages/sonntagnacht/deploy-bundle)[ RSS](/packages/sonntagnacht-deploy-bundle/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)Dependencies (6)Versions (14)Used By (0)

SNDeployBundle
==============

[](#sndeploybundle)

Installation
------------

[](#installation)

```
$ composer require sonntagnacht/deploy-bundle 1.0.1

```

Configuration
-------------

[](#configuration)

Main Configuration for SNDeployBundle

app/config.yml:

```
sn_deploy:
    composer: "/usr/bin/composer"
    default_environment: "prod"                     # default null
    environments:
        prod:
            # host address of webserver
            ssh_host: example.com
            # ssh-user for webserver
            ssh_user: ftp-user
            # ssh-port for rsync
            ssh_port: 22                            # default 22
            # absolute path of web app on remote server
            remote_app_dir: /var/www/html
            # to permit deploy only from one branch
            branch: "production"                    # default null
            # repository version has to be newer then remote version - uses semver
            check_version: true                     # default true
            # customize the rsync transfer settings, parameters below are the default ones
            rsync_options: "--info=progress2 --delete -a"
            # include these files & direcotires, creates a rsync.inlcude file in /tmp/sn-deploy-rsync.include
            # which is used for deployment
            include: []
            # exclude these files & directories, creates a rsync.exclude file in /tmp/sn-deploy-rsync.exclude
            # which is used for deployment
            exclude: []
            # cache clear commands
            cache_clear:
                - "php bin/console cache:clear --prod"
            # local commands before project will upload
            pre_upload: []
            # local commands after project has been uploaded
            post_upload: []
            # remote commands before project will upload
            pre_upload_remote: []
            # remote commands after project has been uploaded
            post_upload_remote: []
```

To get version informations in twig, you have to add `sn_deploy.twig` service in twig globals.

```
twig:
    globals:
        sn_deploy: "@sn_deploy.twig"

```

Usages
------

[](#usages)

### Commands

[](#commands)

Use `sn:deploy [prod|test|dev]` to deploy your project to your webserver.

If you want to upload a bugfix without a new Version use `sn:deploy [prod|test|dev] --hotfix`

### Full Configuration Example

[](#full-configuration-example)

```
sn_deploy:
    composer: "/usr/local/bin/composer"
    environments:
        prod:
            branch: "production"
            ssh_host: 12.34.56.78
            ssh_user: www-data
            remote_app_dir: /var/www/vhosts/mydomain.com
            check_version: true
            cache_clear:
                - "php bin/console redis:flushall -n"
                - "php bin/console cache:clear"
                - "php bin/console cache:clear -e prod"
            exclude:
                - ".DS_Store"
                - "data"
                - "var/cache"
                - "var/logs"
                - "var/sessions"
            pre_upload:
                - "bin/scripts/install_assets.sh"
                - "bin/scripts/generate_assets.sh"
            pre_upload_remote:
                - "/opt/plesk/php/7.0/bin/php bin/console lexik:maintenance:lock"
            post_upload_remote:
                - "/opt/plesk/php/7.0/bin/php bin/console doctrine:migrations:migrate"
                - "/opt/plesk/php/7.0/bin/php bin/console doctrine:schema:update --dump-sql --force"
                - "/opt/plesk/php/7.0/bin/php bin/console fos:elastica:populate"
                - "/opt/plesk/php/7.0/bin/php bin/console lexik:maintenance:unlock"
                - "cat web/.htaccess_prod >> web/.htaccess"
        test:
            ssh_host: 12.34.56.78
            ssh_user: www-data
            remote_app_dir: /var/www/vhosts/test.mydomain.com
            check_version: false
            cache_clear:
                - "php bin/console redis:flushall -n"
                - "php bin/console cache:clear"
                - "php bin/console cache:clear -e prod"
            exclude:
                - ".DS_Store"
                - "data"
                - "var/cache"
                - "var/logs"
                - "var/sessions"
            pre_upload:
                - "bin/scripts/install_assets.sh"
                - "bin/scripts/generate_assets.sh"
            pre_upload_remote:
                - "/opt/plesk/php/7.0/bin/php bin/console lexik:maintenance:lock"
            post_upload_remote:
                - "/opt/plesk/php/7.0/bin/php bin/console doctrine:migrations:migrate"
                - "/opt/plesk/php/7.0/bin/php bin/console doctrine:schema:update --dump-sql --force"
                - "/opt/plesk/php/7.0/bin/php bin/console fos:elastica:populate"
                - "/opt/plesk/php/7.0/bin/php bin/console lexik:maintenance:unlock"
                - "cat web/.htaccess_test >> web/.htaccess"
```

### Twig-Variables

[](#twig-variables)

Get current deployed version use `{{ sn_deploy.version }}`

Get timestamp of last update use `{{ sn_deploy.timestamp|date('Y/m/d H:i') }}`

Get current deployed commit use `{{ sn_deploy.commit }}`

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 74.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~39 days

Recently: every ~27 days

Total

13

Last Release

2908d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/35d7861ab348f8eec53aa5684fce591c55a0c5c8877ad9640ca3c2340361ac30?d=identicon)[sonntagnacht](/maintainers/sonntagnacht)

---

Top Contributors

[![y4roc](https://avatars.githubusercontent.com/u/18329992?v=4)](https://github.com/y4roc "y4roc (55 commits)")[![bartrail](https://avatars.githubusercontent.com/u/293793?v=4)](https://github.com/bartrail "bartrail (17 commits)")[![gherkins](https://avatars.githubusercontent.com/u/824927?v=4)](https://github.com/gherkins "gherkins (2 commits)")

---

Tags

bundledeploymentphpsymfonysymfony-bundle

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sonntagnacht-deploy-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/sonntagnacht-deploy-bundle/health.svg)](https://phpackages.com/packages/sonntagnacht-deploy-bundle)
```

###  Alternatives

[deployer/deployer

Deployment Tool

11.0k25.4M207](/packages/deployer-deployer)[appwrite/server-ce

End to end backend server for frontend and mobile apps.

55.3k84.2k](/packages/appwrite-server-ce)[pragmarx/health

Laravel Server &amp; App Health Monitor and Notifier

2.0k1.0M2](/packages/pragmarx-health)[felixfbecker/language-server-protocol

PHP classes for the Language Server Protocol

22476.7M6](/packages/felixfbecker-language-server-protocol)[heroku/heroku-buildpack-php

Toolkit for starting a PHP application locally, with or without foreman, using the same config for PHP and Apache2/Nginx as on Heroku

8161.3M10](/packages/heroku-heroku-buildpack-php)[tiamo/phpas2

PHPAS2 is a php-based implementation of the EDIINT AS2 standard

4674.7k](/packages/tiamo-phpas2)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
