php-protobuf | Protocol Buffers implementation for PHP
kandi X-RAY | php-protobuf Summary
kandi X-RAY | php-protobuf Summary
Protocol Buffers implementation for PHP
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Serialize the object
- Unserialize a string .
php-protobuf Key Features
php-protobuf Examples and Code Snippets
Community Discussions
Trending Discussions on php-protobuf
QUESTION
currently I'm trying to connect a PHP App in Cloud Foundry with an Oracle Database. For this I need to build the binaries for php with the oci8 driver in order to use pdo_oci in my application. For this I'm using
https://github.com/cloudfoundry/binary-builder
with docker. This seems to work fine. However after this, I don't know how to move on.
I've read the Cloud Foundry Docs about custom Buildpacks ( https://docs.cloudfoundry.org/buildpacks/custom.html ). There they describe the creation of custom Buildpacks in three steps:
Ensure that you have installed the buildpack-packager.
Create a manifest.yml in your buildpack.
Run the packager in cached mode (...)
I've installed the buildpack-manager on my local machine and simply tried to run in against the binaries I've got from the binary builder. I thought it could working since there is a sources.yml file which looks similar to a manifest.yml
...ANSWER
Answered 2019-Jun-20 at 14:44To build a custom PHP buildpack, typically done to include proprietary dependencies like Oracle or SQL Server drivers you can do the following.
Build PHP. This is done with binary-builder. Follow the instructions here. Build as many versions of PHP as you require. This will produce tgz files that contain the binaries.
Host your custom binaries on a web server. This could be local or public, it depends on your needs (see step #5) below.
Clone the PHP Buildpack and checkout one of the stable release tags. Do not build from master as that makes it really hard to know what you're getting or recreate your build. When in doubt, pick the latest tagged release.
Edit the
manifest.yml
file. If it already has entries for the versions of PHP that you built, you can just modify theuri
,sha256
hash andmodules
. You need to add in the additional extensions you compiled to themodules
list. For example, appendoci8
orpdo_oci
to that list. If you're compiling a version of PHP that doesn't existing in the manifest, copy an existing entry and edit all the properties. You can also adjust the manifest to change default versions of PHP or to remove versions you don't want and slim down the buildpack.At this point, you can either commit your changes, push to a fork of the PHP buildpack and set
cf push -b
to point to your fork, or alternatively, you can run the build pack packager and create a buildpack file. You can then take that andcf create-buildpack
orcf update-buildpack
in your foundation (requires admin permissions).If you use
cf push -b
then the binaries you are hosting in step #2 must be accessible from the CF foundation where you are running your application. If you create and upload a buildpack, then the binaries only need to be accessible from the VM where you run build pack packager.
Hope that helps!
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install php-protobuf
PHP requires the Visual C runtime (CRT). The Microsoft Visual C++ Redistributable for Visual Studio 2019 is suitable for all these PHP versions, see visualstudio.microsoft.com. You MUST download the x86 CRT for PHP x86 builds and the x64 CRT for PHP x64 builds. The CRT installer supports the /quiet and /norestart command-line switches, so you can also script it.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page