-
Notifications
You must be signed in to change notification settings - Fork 194
Addition of Amazon S3 tile store module #122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I added support to mod_tile for using an Amazon S3 bucket for metatile storage, using the libs3 library to implement the S3 API communication. This allows a cluster of EC2 tile servers to share a tile store. The changes include:
new store_s3 module with all storage methods implemented. configuration of S3 storage is done using a connection string formatted as follows:
s3://<S3 access key ID>:<S3 secret key>[@<S3 host>]/<bucket name>[/<base path>]
autoconf support for detecting presence of the libs3 library
S3 unit tests in the gen_tile_test program
If autoconf detects the libs3 library, the S3-related tests will be included in gen_tile_test. These tests require environment variables to be set containing the S3 access credentials:
S3_ACCESS_KEY_ID
,S3_SECRET_ACCESS_KEY
, andS3_BUCKET_NAME
. If libs3 support is compiled in, and these environment variables are not defined, gen_tile_test will have failed assertions on that section of the test. I'm certainly open to other options for behavior, but this was simplest.As a possibly optional change, I changed the parameters to the
daemon()
call to allow the working directory and stdout/stderr handles ofrenderd
to be specified in the systemd unit specification (which is launchingrenderd
in our setup). This is certainly not directly required for libs3 support, but should cause no change in behavior in the vast majority of instances. I'm more than willing to drop this change from the PR if you're concerned about the impacts.