Download the PHP package 4msar/laravel-deployer without Composer

On this page you can find all versions of the php package 4msar/laravel-deployer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-deployer

Laravel Deployer

A powerful zero-downtime deployment tool for Laravel applications built with Laravel Zero. Deploy your Laravel applications from GitHub releases with confidence using an easy-to-use CLI tool.

Features

Installation

Via Composer (Recommended)

Via Download

Download the latest laravel-deployer PHAR file from the releases page:

One click install script

Build from Source

Configuration

Using .env File

Copy the example configuration:

Edit .env with your settings:

Using Command Options

You can override configuration using command-line options:

Usage

Basic Deployment

Advanced Options

Full Example

Rollback

Overview

The rollback command allows you to revert to the previous release if something goes wrong. It automatically switches the symlink to point to the previous version and runs health checks.

Basic Usage

How Rollback Works

The rollback process is straightforward and safe:

  1. Validates Installation - Checks if installation exists and is properly set up
  2. Reads Current Version - Gets the current version from version.txt
  3. Finds Releases - Discovers all available releases and identifies the previous one
  4. Displays Options - Shows all releases with their status (Current/Previous)
  5. User Confirmation - Asks for confirmation before rolling back
  6. Switch Release - Updates symlink to point to the previous release
  7. Optimize - Runs Laravel cache clearing and caching commands
  8. Update Version - Updates version.txt with the previous version
  9. Health Check - Verifies the application is working after rollback

Example Rollback Scenario

Release Requirements

How It Works

  1. Fetch Release: Downloads the latest release from GitHub
  2. Prepare: Extracts the release to a temporary directory
  3. Preserve Files: Copies important files from current installation (.env, storage, etc.)
  4. Deploy: Creates a new release directory and copies files
  5. Optimize: Runs Laravel optimization commands (config, route, view cache)
  6. Migrate: Optionally runs database migrations
  7. Switch: Updates symlink to point to new release
  8. Health Check: Verifies the application is working
  9. Cleanup: Removes old releases (optional)
  10. Rollback: Automatically rolls back on failure

Directory Structure

After deployment, your directory structure will look like:

Requirements

GitHub Token

For private repositories or to avoid rate limiting, create a GitHub Personal Access Token:

  1. Go to https://github.com/settings/tokens
  2. Click "Generate new token (classic)"
  3. Select scopes: repo (for private repos) or public_repo (for public repos)
  4. Copy the token and use it with --github-token option or in .env

Deployment Best Practices

  1. Test Locally: Always test your release locally before deploying
  2. Backup Database: Backup your database before running migrations
  3. Use Releases: Tag your code with semantic versioning (v1.0.0, v1.1.0, etc.)
  4. Preserve Files: Ensure all important files are listed in config
  5. Health Checks: Verify your application after deployment
  6. Keep Releases: Keep at least 2 previous releases for quick rollback

Troubleshooting

Permission Denied

Run with sudo or ensure your user has write permissions:

GitHub Rate Limiting

Use a GitHub token to increase rate limits:

Migration Failures

Skip migrations and run them manually:

Rollback Manually

Use the built-in rollback command:

Or manually create the symlink (requires knowing the previous release name):

Self Update

To update laravel-deployer to the latest version, run:

It will download and replace the current PHAR with the latest release.

License

This project is open-sourced software licensed under the MIT license.

Credits

Built with Laravel Zero - The PHP framework for console applications.


All versions of laravel-deployer with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
ext-zip Version *
guzzlehttp/guzzle Version ^7.8
illuminate/http Version ^12.17
laravel-zero/phar-updater Version ^1.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package 4msar/laravel-deployer contains the following files

Loading the files please wait ...