timberhub / laravel-deployments
A simple CLI tool to deploy Laravel applications.
Installs: 2 090
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 0
Forks: 0
Open Issues: 0
Requires
- php: ^8.2.0
- laravel/forge-sdk: ^3.13.5
- symfony/console: ^6.0.9
- dev-main
- v0.2.18
- v0.2.17
- v0.2.16
- v0.2.15
- v0.2.14
- v0.2.13
- v0.2.12
- v0.2.11
- v0.2.10
- v0.2.9
- v0.2.8
- v0.2.7
- v0.2.6
- v0.2.5
- v0.2.4
- v0.2.3
- v0.2.2
- v0.2.1
- v0.2.0
- v0.1.6
- v0.1.5
- v0.1.4
- v0.1.3
- v0.1.2
- v0.1.1
- v0.1.0
- dev-add-it
- dev-customer-io
- dev-supabase-connection
- dev-remove-deamon-create-functionality
- dev-change-default-php-version
- dev-feature/supabase-env-update
- dev-fix-php-version
- dev-set-php-version
- dev-Ignore-idea-folder
- dev-accept-php-version
- dev-add-prefix-to-APP_ENV
This package is auto-updated.
Last update: 2024-12-21 15:44:42 UTC
README
This a repository/package that can be used to deploy your Laravel application to a server. The main and final outcome are commands with parameters on target servers and extra actions that need to take place.
Usage
You can use it either by installing it to your Laravel project or in a GitHub Action. (We will further update soon with a GitHub Action Marketplace link)
Install to your Laravel project
Install the package with composer:
composer require timberhub/laravel-deployments
Use the command helper to adjust the parameters. e.g:
./vendor/bin/ci-actions branch:deploy:forge -h
Deploy to a Forge Server
Use the following command to deploy your application to a Forge server like this:
./vendor/bin/ci-actions branch:deploy:forge \ --token=[FORGE_API_TOKEN] \ --server=[FORGE_SERVER_ID] \ --branch=[BRANCH_NAME] \ --repository=[REPOSITORY_URL] \ --branch=[BRANCH_NAME] \ --domain=[DOMAIN_NAME] \ --php-version=[PHP_VERSION] \ --db-name=[DB_NAME] \ --db-user=[DB_USER] \ --db-password=[DB_PASSWORD]
Then you can add extra parameters like the environment variables you want to set on the server, or commands that you want to run after the deployment. Those commands could be your own deployment script to finalize the installation of your application.
PS: Make sure your domain name points to the server you are deploying to before you run the command. The deployment URL will look like https://[BRANCH_NAME].[REPOSITORY_NAME][DOMAIN_NAME].
.
Create a release
git tag -a [version] -m "[title]"
git push origin tag [version]