Skip to content

Dylan-Buth/lumen-starter

 
 

Repository files navigation

Lumen Starter Template Build Status

This Laravel Lumen starter template is intended to be used for new projects.

README Contents

For details on how to contribute to this repo, please check out the contributing guide.

### What's Included ### Using This Repository

We recommend watching this repository so you can apply updates made to this project to yours.

Realpage teams should contact [email protected] using this email template to get everything setup.

For everyone else:

  1. Clone this repo and delete the .git directory
  2. Run git init and change the origin of the repo to point to your remote repository
  3. Reference the contributing guide for running this application locally
  4. After running locally docker exec -it $(docker ps -f name=fpm -q) php artisan clean:template to strip out example migrations, seeds, tests, etc...

Dockerhub Setup

Create a repository that mirrors your GitHub namespace/repository except does not include dashes (DockerHub doesn't allow dashes). The travis configuration is already designed to handle this transition for you. An example of this would be:

GitHub: my-namespace/my-new-project

DockerHub: mynamespace/mynewproject

Travis-CI Setup

Configure the following environment variables:

  • DOCKER_EMAIL
  • DOCKER_USERNAME
  • DOCKER_PASSWORD

This user needs to have permission to write to the DockerHub repository so that it can push images.

### Testing
  • Dredd support for ensuring accurate API documentation. Can also be considered as acceptance tests
  • PHPUnit for unit/functional testing

For more on testing, please see: Testing in the Lumen Starter on YouTube.

### FAQ ##### **How can I use MySQL?** * Set the `DB_CONNECTION` environment variable to `mysql` * Update the fpm/cli docker containers to `apt-get install php7.0-mysql`
  • the default.conf file located in the infrastructure/nginx directory will be added to the nginx container as part of the build
  • update the file and rebuild the container via docker-compose build to propagate the changes
Is there a shortcut for running commands within specific containers?

Yes! Using an alias below, you can run commands in containers with dockerexc fpm php -v instead of docker exec -it $(docker ps -f name=fpm -q) php -v.

alias dockerexc='function _docker_exec(){ service=$1; shift; docker exec -it $(docker-compose ps -q ${service}) "$@" };_docker_exec'

About

A pre-configured Lumen app to jumpstart development

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 88.9%
  • API Blueprint 10.0%
  • ApacheConf 1.1%