Skip to content

Commit

Permalink
Update php-laravel devfile (devfile#349)
Browse files Browse the repository at this point in the history
* Update php-laravel devfile

Signed-off-by: dkwon17 <[email protected]>

* Update endpoint name

Co-authored-by: Theofanis Petkos <[email protected]>
Signed-off-by: dkwon17 <[email protected]>

---------

Signed-off-by: dkwon17 <[email protected]>
Co-authored-by: Theofanis Petkos <[email protected]>
Signed-off-by: thepetk <[email protected]>
  • Loading branch information
dkwon17 and thepetk committed Apr 22, 2024
1 parent 541dcd1 commit e9310bb
Show file tree
Hide file tree
Showing 2 changed files with 99 additions and 1 deletion.
97 changes: 97 additions & 0 deletions stacks/php-laravel/2.0.1/devfile.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
schemaVersion: 2.2.2
metadata:
name: php-laravel
displayName: Laravel
description: "Laravel is an open-source PHP framework, which is robust and easy to understand.
It follows a model-view-controller design pattern.
Laravel reuses the existing components of different frameworks which helps in creating a web application.
The web application thus designed is more structured and pragmatic."
icon: https://raw.githubusercontent.com/devfile-samples/devfile-stack-icons/main/laravel.svg
tags:
- PHP
- Composer
- Laravel
projectType: Laravel
language: PHP
provider: Red Hat
version: 2.0.1
starterProjects:
- name: php-laravel-starter
git:
checkoutFrom:
revision: main
remotes:
origin: https://github.com/devfile-samples/devfile-stack-php-laravel.git
components:
- container:
endpoints:
- name: https-laravel
targetPort: 8000
protocol: https
image: quay.io/devfile/composer:2.5.8
args: ["tail", "-f", "/dev/null"]
memoryLimit: 1024Mi
mountSources: true
name: runtime
commands:
- exec:
commandLine: composer install
component: runtime
group:
isDefault: false
kind: build
workingDir: ${PROJECT_SOURCE}
id: install
- exec:
commandLine: cp .env.example .env
component: runtime
group:
isDefault: false
kind: build
workingDir: ${PROJECT_SOURCE}
id: cp-env
- exec:
commandLine: php artisan config:clear
component: runtime
group:
isDefault: false
kind: build
workingDir: ${PROJECT_SOURCE}
id: clear-config
- exec:
commandLine: php artisan key:generate
component: runtime
group:
isDefault: false
kind: build
workingDir: ${PROJECT_SOURCE}
id: gen-new-app-key
- exec:
commandLine: composer dump-autoload
component: runtime
group:
isDefault: false
kind: build
workingDir: ${PROJECT_SOURCE}
id: composer-dump
- composite:
commands:
- install
- cp-env
- clear-config
- gen-new-app-key
- composer-dump
group:
isDefault: true
kind: build
label: Provision Laravel Server
parallel: false
id: init-server
- exec:
commandLine: php artisan serve --host=0.0.0.0
component: runtime
group:
isDefault: true
kind: run
workingDir: ${PROJECT_SOURCE}
id: run
3 changes: 2 additions & 1 deletion stacks/php-laravel/stack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@ displayName: Laravel
icon: https://raw.githubusercontent.com/devfile-samples/devfile-stack-icons/main/laravel.svg
versions:
- version: 1.0.1
default: true
- version: 2.0.0
- version: 2.0.1
default: true

0 comments on commit e9310bb

Please sign in to comment.