-
-
Save ccamacho/ceaff0833eaaff2d2868a32c32a7510a to your computer and use it in GitHub Desktop.
ansible role to mount s3 buckets on ec2 -- http://juliensimon.blogspot.com/2013/08/howto-aws-mount-s3-buckets-from-linux.html
This file contains 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
--- | |
- include_vars: secrets.yml | |
- apt: pkg={{ item }} state=present update_cache=yes | |
with_items: | |
- build-essential | |
- mime-support | |
- libfuse-dev | |
- libcurl4-openssl-dev | |
- libxml++2.6-dev | |
- libssl-dev | |
- autoconf | |
- get_url: url=https://github.com/s3fs-fuse/s3fs-fuse/archive/v1.79.tar.gz dest=/tmp/s3fs.tar.gz | |
- command: tar xvf s3fs.tar.gz chdir=/tmp creates=s3fs-fuse-1.79 | |
- command: ./autogen.sh chdir=/tmp/s3fs-fuse-1.79 | |
- command: ./configure --prefix=/usr chdir=/tmp/s3fs-fuse-1.79 creates=config.status | |
- command: make chdir=/tmp/s3fs-fuse-1.79 creates=src/s3fs | |
- command: make install chdir=/tmp/s3fs-fuse-1.79 creates=/usr/local/bin/s3fs | |
- template: src=passwd-s3fs.j2 dest=/root/.passwd-s3fs mode=0600 | |
- file: path=/mnt/s3 state=directory mode=0777 | |
- file: path=/tmp/cache state=directory mode=0777 | |
- command: s3fs -o use_cache=/tmp/cache {{ bucket }} /mnt/s3 |
This file contains 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
{{ access_key_id }}:{{ secret_access_key }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment