Michael Gapczynski dd8303b975 Stop AWS SDK from looking for configuration files, forgot to include lib/cachecore | 12 年之前 | |
---|---|---|
.. | ||
_compatibility_test | 12 年之前 | |
_docs | 12 年之前 | |
authentication | 12 年之前 | |
lib | 12 年之前 | |
services | 12 年之前 | |
utilities | 12 年之前 | |
README.md | 12 年之前 | |
sdk.class.php | 12 年之前 |
The AWS SDK for PHP enables developers to build solutions for Amazon Simple Storage Service (Amazon S3), Amazon Elastic Compute Cloud (Amazon EC2), Amazon SimpleDB, and more. With the AWS SDK for PHP, developers can get started in minutes with a single, downloadable package.
The SDK features:
For more information about the AWS SDK for PHP, including a complete list of supported services, see aws.amazon.com/sdkforphp.
Before you can begin, you must sign up for each service you want to use.
To sign up for a service:
The source tree for includes the following files and directories:
_compatibility_test
-- Includes both an HTML-based and a CLI-based SDK Compatibility Test that you can
run on your server to determine whether or not your PHP environment meets the minimum requirements._docs
-- Informational documents, the contents of which should be fairly self-explanatory._samples
-- Code samples that you can run out of the box.extensions
-- Extra code that can be used to enhance usage of the SDK, but isn't a service class or a
third-party library.lib
-- Contains any third-party libraries that the SDK depends on. The licenses for these projects will
always be Apache 2.0-compatible.services
-- Contains the service-specific classes that communicate with AWS. These classes are always
prefixed with Amazon
.utilities
-- Contains any utility-type methods that the SDK uses. Includes extensions to built-in PHP
classes, as well as new functionality that is entirely custom. These classes are always prefixed with CF
.README
-- The document you're reading right now.config-sample.inc.php
-- A sample configuration file that should be filled out and renamed to config.inc.php
.sdk.class.php
-- The SDK loader that you would include in your projects. Contains the base functionality
that the rest of the SDK depends on.If you're not sure whether your PHP environment meets these requirements, run the SDK Compatibility Test script included in the SDK download.
Git is an extremely fast, efficient, distributed version control system ideal for the collaborative development of software. GitHub is the best way to collaborate with others. Fork, send pull requests and manage all your public and private git repositories. We believe that GitHub is the ideal service for working collaboratively with the open source PHP community.
Git is primarily a command-line tool. GitHub provides instructions for installing Git on Mac OS X, Windows, and Linux. If you're unfamiliar with Git, there are a variety of resources on the net that will help you learn more:
If you're comfortable working with Git and/or GitHub, you can pull down the source code as follows:
git clone git://github.com/amazonwebservices/aws-sdk-for-php.git AWSSDKforPHP
cd ./AWSSDKforPHP
PEAR stands for the PHP Extension and Application Repository and is a framework and distribution system for reusable PHP components. It is the PHP equivalent to package management software such as MacPorts and Homebrew for Mac OS X, Yum and Apt for GNU/Linux, RubyGems for Ruby, Easy Install for Python, Maven for Java, and NPM for Node.js.
PEAR packages are very easy to install, and are available in your PHP environment path so that they are accessible to any PHP project. PEAR packages are not specific to your project, but rather to the machine that they're installed on.
From the command-line, you can install the SDK with PEAR as follows:
pear channel-discover pear.amazonwebservices.com
pear install aws/sdk
You may need to use sudo
for the above commands. Once the SDK has been installed via PEAR, you can load it into
your project with:
require_once 'AWSSDKforPHP/sdk.class.php';
~/.aws/sdk/config.inc.php
.getenv('HOME')
points to your user directory. If not you'll need to set
putenv('HOME=<your-user-directory>')
.