Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/aminnairi/lucern

PHP framework for creating HTTP APIs
https://github.com/aminnairi/lucern

api docker docker-compose framework http php

Last synced: about 5 hours ago
JSON representation

PHP framework for creating HTTP APIs

Awesome Lists containing this project

README

        

# lucern

PHP framework for creating HTTP APIs

## Requirements

- [GNU/Bash](https://www.gnu.org/software/bash/)
- [GNU/Make](https://www.gnu.org/software/make/)
- [Git](https://git-scm.com/)
- [Docker](https://www.docker.com/)
- [Docker Compose](https://docs.docker.com/compose/)

## Clone

```bash
git clone https://github.com/aminnairi/docker-php-nginx-mariadb-template my-project
cd my-project
```

## Setup

```bash
cp .env.example .env
```

> *Note: edit the `.env` file to setup your environment.*

## Startup

```bash
make start
```

> *Note: you can change the port listened by the server with the `SERVER_PORT` environment variable by editing it in the `.env` file.*

## Database

```bash
make database
```

> *Note: this will login to your database using a command line interface using your environment setup.*

## Migration

```bash
make migration
```

> *Note: this migrate the datamodel into the SQL database.*

## Shutdown

```bash
make stop
```

## Restart

```bash
make restart
```

> *Note: this is equivalent to running `make stop start`.*

## PHP

```bash
docker compose exec php php --version
```

> *Note: replace `--version` with the PHP argument of your choice.*

## MariaDB

```bash
docker compose exec mariadb mariadb --version
```

> *Note: replace `--version` with the MariaDB argument of your choice.*