Skip to content

Commit

Permalink
Merge pull request #48 from SaravanaStorageNetwork/renamed_s3
Browse files Browse the repository at this point in the history
Rename docker-gluster-swift
  • Loading branch information
humblec committed Jul 31, 2017
2 parents 83a8491 + d9b3583 commit 4757dd9
Show file tree
Hide file tree
Showing 20 changed files with 19 additions and 20 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Expand Up @@ -25,10 +25,10 @@ before_install:
- docker run -d --name gfedora --privileged -v /sys/fs/cgroup:/sys/fs/cgroup:ro gluster/fedora
- sleep 10
- docker exec -it gfedora systemctl is-active glusterd
- docker build -t gluster/swift ./gluster-object/CentOS/docker-gluster-swift/
- docker run -d --name swift --privileged -v /sys/fs/cgroup:/sys/fs/cgroup:ro -e GLUSTER_VOLUMES=vol gluster/swift
- docker build -t gluster/s3object ./gluster-s3object/CentOS/docker-gluster-s3/
- docker run -d --name s3object --privileged -v /sys/fs/cgroup:/sys/fs/cgroup:ro -e GLUSTER_VOLUMES=vol gluster/s3object
- sleep 10
- docker exec -it swift systemctl is-active swift-object
- docker exec -it s3object systemctl is-active swift-object

script:
- make test
11 changes: 5 additions & 6 deletions README.md
Expand Up @@ -114,17 +114,16 @@ Number of Peers: 0
~~~
That’s it!


Additional Ref# https://goo.gl/3031Mm

## Gluster Object Docker container:

### To pull gluster-object:
### To pull gluster-s3:
~~~
$ docker pull gluster/gluster-object
$ docker pull gluster/gluster-s3
~~~

### To run gluster-object container:
### To run gluster-s3 container:

On the host machine, mount one or more gluster volumes under the directory
`/mnt/gluster-object` with mountpoint name being same as that of the volume.
Expand All @@ -143,10 +142,10 @@ GLUSTER_VOLUMES='tv1'
Where tv1 is the volume name.

~~~
$ docker run -d --privileged -v /sys/fs/cgroup/:/sys/fs/cgroup/:ro -p 8080:8080 -v /mnt/gluster-object:/mnt/gluster-object gluster/gluster-object
$ docker run -d --privileged -v /sys/fs/cgroup/:/sys/fs/cgroup/:ro -p 8080:8080 -v /mnt/gluster-object:/mnt/gluster-object gluster/gluster-s3
~~~

Now, We can get/put objects into the gluster volume, using the gluster-object Docker container.
Now, We can get/put objects into the gluster volume, using the gluster-s3 Docker container.
Refer this link[1] for testing.

[1] https://github.com/gluster/gluster-swift/blob/master/doc/markdown/quick_start_guide.md#using_swift
Expand Down
@@ -1,13 +1,13 @@

# docker-gluster-swift
docker-gluster-swift is to provide object interface for a Gluster volume.
# docker-gluster-s3
docker-gluster-s3 is to provide object interface for a Gluster volume.

Let us see how to run gluster-swift inside a docker container.
Let us see how to run gluster-s3 inside a docker container.

## Building

```bash
# docker build --rm --tag gluster-swift .
# docker build --rm --tag gluster-s3 .
```

## Running
Expand All @@ -30,7 +30,7 @@ Where tv1 is the volume name.
**Example:**

```bash
# docker run -d --privileged -v /sys/fs/cgroup/:/sys/fs/cgroup/:ro -p 8080:8080 -v /mnt/gluster-object:/mnt/gluster-object -e GLUSTER_VOLUMES="tv1" gluster-swift
# docker run -d --privileged -v /sys/fs/cgroup/:/sys/fs/cgroup/:ro -p 8080:8080 -v /mnt/gluster-object:/mnt/gluster-object -e GLUSTER_VOLUMES="tv1" gluster-s3
```

If you have selinux set to enforced on the host machine, refer to the
Expand Down Expand Up @@ -63,7 +63,7 @@ Assuming you have conf files and ring files present at `/tmp/swift` on the
machine, you can spawn the container as follows:

```bash
# docker run -d -p 8080:8080 -v /tmp/swift:/etc/swift -v /mnt/gluster-object:/mnt/gluster-object prashanthpai/gluster-swift:dev
# docker run -d -p 8080:8080 -v /tmp/swift:/etc/swift -v /mnt/gluster-object:/mnt/gluster-object gluster-s3
```

If the host machine has SELinux set to enforced:
Expand Down Expand Up @@ -106,4 +106,4 @@ mount -t glusterfs -o selinux,context="system_u:object_r:svirt_sandbox_file_t:s0

### TODO

* Install gluster-swift from RPMs. (Currently installed from source)
* Install gluster-s3 from RPMs. (Currently installed from source)
8 changes: 4 additions & 4 deletions tests/shelltest/test_gluster_container_basic.sh
Expand Up @@ -35,12 +35,12 @@ testit "test shellcheck ${BASE_DIR}/CentOS/gluster-setup.sh" \
test_shellcheck ${BASE_DIR}/CentOS/gluster-setup.sh \
|| ((failed++))

testit "test script syntax ${BASE_DIR}/gluster-object/CentOS/docker-gluster-swift/update_gluster_vol.sh" \
test_syntax ${BASE_DIR}/gluster-object/CentOS/docker-gluster-swift/update_gluster_vol.sh \
testit "test script syntax ${BASE_DIR}/gluster-s3object/CentOS/docker-gluster-s3/update_gluster_vol.sh" \
test_syntax ${BASE_DIR}/gluster-s3object/CentOS/docker-gluster-s3/update_gluster_vol.sh \
|| ((failed++))

testit "test shellcheck ${BASE_DIR}/gluster-object/CentOS/docker-gluster-swift/update_gluster_vol.sh" \
test_shellcheck ${BASE_DIR}/gluster-object/CentOS/docker-gluster-swift/update_gluster_vol.sh \
testit "test shellcheck ${BASE_DIR}/gluster-s3object/CentOS/docker-gluster-s3/update_gluster_vol.sh" \
test_shellcheck ${BASE_DIR}/gluster-s3object/CentOS/docker-gluster-s3/update_gluster_vol.sh \
|| ((failed++))


Expand Down

0 comments on commit 4757dd9

Please sign in to comment.