Download the PHP package brunocfalcao/larapush without Composer

On this page you can find all versions of the php package brunocfalcao/larapush. 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 larapush

Larapush logo


Latest Stable Version Total Downloads License

Deploy your codebase to your web server using a new Laravel Artisan command

php artisan push

Features

Requirements

Database is only needed in your web server (Laravel Passport will be installed)
PHP 7.2+
Laravel 5.8+

Installation

:exclamation: In order to generate your OAuth client and token, you need to first install Larapush on your web server!

Log in into your web server and run the following commands:

At the end, it will generate your command line that you will need to use to install it on your local computer. As example:

:exclamation: Now copy+paste the one generated on your web server so you can use it later on your local installation.

On your local development computer, run the following commands:

Now paste the line from your previous web server installation to your local computer prompt. Here is an example:

The installer will prompt to insert your web server URL. Just add it in the FQDN format (e.g.: https://www.johnsmith.com).

The installation completes you should see:

Usage

Henceforth all you have to do is to run the command:

It will upload your codebase that you define on your larapush.php configuration file (larapush.codebase) and the scripts that you also specified (larapush.scripts).

Configuration

A new larapush.php configuration file is created. Let's explore it.

larapush.type

No need to change this, it is automatically configured by the installers using .env keys that will be registered.

larapush.environment

If your web server environment name matches one of the ones specified here, then Larapush will ask you to confirm the upload each time you push your code. This will avoid you to upload your codebase to environments that you might not want to (like a production).

larapush.remote

No need to change these keys by default, unless you want to change the main root URL path, or force a web server URL.

larapush.scripts (pre_scripts and post_scripts)

You can specify actions to run before and after the code is deployed on your web server. For each, you can:

You can add as much as you want. All outputs are stored inside your transaction folder (later to be explained).

larapush.codebase

Important part, where you can specify your codebase folders and files. Just add them as array values, E.g.:

larapush.storage

This is the path where all of your codebase push transactions are stored. See it like a versioning way of storing all of your codebase along time.

larapush.oauth

These are security tokens generated by Laravel Passport. Don't change them, they are recorded on your .env file.

larapush.token

This is an extra security layer, of a token that needs to be the same in both web server and your local dev computer. Registered via your installation process.

Codebase transaction repository

Each time you upload your codebase, Larapush stores that codebase plus your configured "pre" and "post" scripts both in your local computer and in your web server. This is called a transaction. By default these transaction folders are on your storage_path("app/larapush"). You can change this path on your larapush.php configuration file.

As example, you are pushing your codebase and you see this line on your artisan command info:

That code between parenthesis is the transaction code. If you navigate to your storage-path/app/larapush you will see all the transaction folders listed there. Each of those correspond to a push you have made to your web server.

Here is an example of the folders location:
Codebase transaction folders

In your web server it works exactly the same way. Additionally on each of the folder you might see also 2 files:

Those are the console exports of the scripts that ran on each of your codebase push. So, in case you are running scripts you will see your console output there. Nice, heim? :)

Security above all

Larapush was developed taking security very seriously. At the end, anyone that knows your endpoint would be able to upload a malicious codebase to your web server. That's why Larapush uses OAuth client grant access tokens for each of the HTTP transactions that are handshaken between your web server and your local computer. At the end of the HTTP transaction, the client access token is marked as used, so it cannot be used again.

When you install Larapush on your web server, it installs Laravel Passport and generates a specific client token that will be unique between your web server and your local computer. Henceforth any transaction between your local computer and your web server needs to first request a new client grant token and then use that token on the respective HTTP call. Additionally there is also a token that is passed on each request that needs to be the same between your local computer and the web server. If not, the transaction aborts in error.

All of this is done automatically each time you push your codebase. Nice and smooth!

Security

If you find any security related issue please send me a direct email.

License

The MIT License (MIT). Please see License File for more information.


All versions of larapush with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2
illuminate/support Version ^5.8.15|^6.0|^7.0
kitetail/zttp Version ^0.6
sixlive/dotenv-editor Version ^1.2
laravel/helpers Version ^1.0
brunocfalcao/helpers Version ^1.0
nelexa/zip Version ^3.1
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 brunocfalcao/larapush contains the following files

Loading the files please wait ....