go-ceph/Dockerfile
Lincoln Thurlow ecf9a99249 cephfs: add unmount, release, chmod, chown, etc
This commit adds the following cephfs functions:

* Unmount // Unmounting is necessary to cleanup mounts
* Release // Release destroys the cmount ~ end of transaction
* RemoveDir // inverse of MakeDir
* Chown // change ownership of file or directory
* Chmod // change permissions of file or directory

Tests are included for each function.

In addition to these changes modifications to:

.travis.yml, Dockerfile, and Makefile

were made to accomodate tests to mount the ceph volume.  Tests use
fuse to mount the volume which requires adding:

--device /dev/fuse --cap-add SYS_ADMIN --security-opt \
apparmor:unconfined

to the docker container (alternatively --privileged works but adds
additional permissions).

Changes to README add the above docker changes as well as point
users to the necessary ceph development libraries.
2018-10-11 11:09:16 -07:00

34 lines
773 B
Docker

FROM ubuntu:xenial
RUN apt-get update && apt-get install -y \
apt-transport-https \
git \
software-properties-common \
uuid-runtime \
wget
ARG CEPH_REPO_URL=https://download.ceph.com/debian-luminous/
RUN wget -q -O- 'https://download.ceph.com/keys/release.asc' | apt-key add -
RUN apt-add-repository "deb ${CEPH_REPO_URL} xenial main"
RUN add-apt-repository ppa:gophers/archive
RUN apt-get update && apt-get install -y \
ceph \
libcephfs-dev \
librados-dev \
librbd-dev \
golang-1.10-go
# add user account to test permissions
RUN groupadd -g 1010 bob
RUN useradd -u 1010 -g bob -M bob
ENV GOPATH /go
WORKDIR /go/src/github.com/ceph/go-ceph
VOLUME /go/src/github.com/ceph/go-ceph
COPY micro-osd.sh /
COPY entrypoint.sh /
ENTRYPOINT /entrypoint.sh