All Projects → ZeroSharp → Serverless Php

ZeroSharp / Serverless Php

Licence: other
Serverless Framework example using an AWS lambda which runs a PHP function

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Serverless Php

Serverless Plugin Git Variables
⚡️ Expose git variables to serverless
Stars: ✭ 75 (-48.63%)
Mutual labels:  aws-lambda, serverless-framework
Serverless
⚡ Serverless Framework – Build web, mobile and IoT applications with serverless architectures using AWS Lambda, Azure Functions, Google CloudFunctions & more! –
Stars: ✭ 41,584 (+28382.19%)
Mutual labels:  aws-lambda, serverless-framework
Alexa Skill Serverless Starter Template
An Alexa Skill starter project template that uses the Serverless Framework and the Alexa Skills Kit SDK for Node.js
Stars: ✭ 81 (-44.52%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Sam
Serverless framework plugin to export AWS SAM templates for a service
Stars: ✭ 143 (-2.05%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Architectures Aws
The code repository for the Serverless Architectures on AWS book
Stars: ✭ 120 (-17.81%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Node Simple Image Resize
Simple image resize AWS lambda function
Stars: ✭ 74 (-49.32%)
Mutual labels:  aws-lambda, serverless-framework
Serverless With Next5 Boilerplate
Serverless.js with Next.js 5 on AWS, powered by the Serverless Framework
Stars: ✭ 100 (-31.51%)
Mutual labels:  aws-lambda, serverless-framework
Graphql Serverless
Sample project to guide the use of GraphQL and Serverless Architecture.
Stars: ✭ 28 (-80.82%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Side Rendering React Next
Sample repo for setting up Next and React on AWS Lambda with the Serverless Framework.
Stars: ✭ 117 (-19.86%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Docker Image Resize
Simple serverless image resize on-the-fly - Deploy with one command - Built with AWS Lambda and S3
Stars: ✭ 114 (-21.92%)
Mutual labels:  aws-lambda, serverless-framework
Ng Toolkit
⭐️ Angular tool-box! Start your PWA in two steps! Add Serverless support for existing projects and much more
Stars: ✭ 1,116 (+664.38%)
Mutual labels:  aws-lambda, serverless-framework
A Crash Course On Serverless Auth
A short and easy boilerplate showcasing JWT auth with Nodejs, the Serverless framework, MongoDB and AWS Lambda.
Stars: ✭ 127 (-13.01%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Es Logs
A Serverless plugin to transport logs to ElasticSearch
Stars: ✭ 51 (-65.07%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Node Simple Messaging
Simple email AWS lambda function
Stars: ✭ 75 (-48.63%)
Mutual labels:  aws-lambda, serverless-framework
Chalice
Python Serverless Microframework for AWS
Stars: ✭ 8,513 (+5730.82%)
Mutual labels:  aws-lambda, serverless-framework
Kinesis Streams Fan Out Kinesis Analytics
Amazon Kinesis Streams fan-out via Kinesis Analytics (powered by the Serverless Framework)
Stars: ✭ 95 (-34.93%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Plugin Typescript
Serverless plugin for zero-config Typescript support
Stars: ✭ 611 (+318.49%)
Mutual labels:  aws-lambda, serverless-framework
Serverless Aws Lambda Node Postgres
Serverless AWS Lambda with Node.js,Postgres Rest API with Sequelize.
Stars: ✭ 18 (-87.67%)
Mutual labels:  aws-lambda, serverless-framework
Awesome Layers
λ A curated list of awesome AWS Lambda Layers. Sponsored by https://cloudash.dev
Stars: ✭ 1,655 (+1033.56%)
Mutual labels:  aws-lambda, serverless-framework
Serverless
Serverless 架构应用开发指南 - Serverless Architecture Application Development Guide with Serverless Framework.
Stars: ✭ 1,616 (+1006.85%)
Mutual labels:  aws-lambda, serverless-framework

PHP with the Serverless Framework

In order to use PHP on AWS Lambda you need to bundle the PHP binary, including the required libraries, into the package. This serverless example project includes the necessary binary to run a simple PHP script.

See my blog post here.

Prerequisites

Install this serverless project. It will create a new serverless-php folder.

serverless install --url https://github.com/ZeroSharp/serverless-php

Deploying the sample function to AWS

Check the serverless.yml file and modify region and stage if necessary.

sls deploy

Running the function locally

sls invoke local --function hello

Running the function on AWS

sls invoke --function hello

Rebuilding the PHP binary

If you need different compiler flags or dependencies you will need to recompile PHP.

Prerequisites

Compile the static standalone PHP 7 binary

To do this, we have to compile the PHP 7.2.2 with statically linked libraries:

sh buildphp.sh

PHP Version

The default is to use the PHP 7.2.2 branch to compile the PHP binary. To switch the PHP version you can set the branch PHP_VERSION_GIT_BRANCH parameter in buildphp.sh line 8.

Thanks

Thanks to:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].