mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-04-23 12:38:21 -05:00
remove eos related stuff (leave documentation)
This commit is contained in:
@@ -1,24 +0,0 @@
|
||||
FROM owncloud/eos-base:4.8.26
|
||||
|
||||
ENV CGO_ENABLED=1
|
||||
ENV GOOS=linux
|
||||
|
||||
RUN rpm --rebuilddb && yum -y install \
|
||||
wget \
|
||||
time \
|
||||
make \
|
||||
gcc \
|
||||
git
|
||||
|
||||
RUN wget -q https://dl.google.com/go/go1.15.7.linux-amd64.tar.gz
|
||||
RUN mkdir -p /usr/local/bin
|
||||
RUN tar xf go1.15.7.linux-amd64.tar.gz -C /usr/local
|
||||
RUN ln -s /usr/local/go/bin/* /usr/local/bin
|
||||
|
||||
COPY entrypoint /entrypoint
|
||||
COPY start-ldap /start-ldap
|
||||
|
||||
VOLUME [ "/ocis" ]
|
||||
WORKDIR /ocis
|
||||
|
||||
|
||||
@@ -1,88 +0,0 @@
|
||||
# Docker image for oCIS development with eos
|
||||
|
||||
Image is based on [owncloud/eos-base](https://hub.docker.com/r/owncloud/eos-base) from [eos-stack](https://github.com/owncloud-docker/eos-stack)
|
||||
|
||||
{{< hint info >}}
|
||||
On MacOS do not mount a local folder to the `/var/tmp/reva/` path. The fuse driver used by docker [does not support extended attributes](https://docs.docker.com/v18.09/docker-for-mac/osxfs/). See [#182](https://github.com/owncloud/ocis/issues/182) for more details.
|
||||
{{< /hint >}}
|
||||
|
||||
## Build
|
||||
```shell
|
||||
docker build -t owncloud/eos-ocis-dev:latest .
|
||||
```
|
||||
|
||||
## Publish
|
||||
```shell
|
||||
docker push owncloud/eos-ocis-dev:latest
|
||||
```
|
||||
|
||||
## Maintainer
|
||||
|
||||
* [Felix Böhm](https://github.com/felixboehm)
|
||||
|
||||
## Disclaimer
|
||||
Use only for development or testing. Setup is not secured nor tested.
|
||||
|
||||
## oCIS development on eos
|
||||
|
||||
### Setup oCIS
|
||||
|
||||
To build and run your local ocis code with default storage driver
|
||||
|
||||
```shell
|
||||
docker run --rm -ti --name ocis -v $PWD:/ocis -p 9200:9200 owncloud/eos-ocis-dev
|
||||
```
|
||||
|
||||
ocis will use the owncloud storage driver and store files in the container at /var/tmp/reva/data/<username>/files
|
||||
|
||||
Data is here: `docker exec -it ocis ll /var/tmp/reva/`
|
||||
|
||||
Alternative: With the [docker-compose.yml file in ocis repo](https://github.com/owncloud/ocis/blob/master/docker-compose.yml) you can also start ocis via compose:
|
||||
|
||||
```shell
|
||||
docker-compose up -d ocis
|
||||
```
|
||||
|
||||
Now try to list the running services
|
||||
|
||||
```shell
|
||||
docker-compose exec ocis ./bin/ocis list
|
||||
```
|
||||
|
||||
## Setup eos storage
|
||||
|
||||
1. Start the eos cluster and ocis via the compose stack
|
||||
|
||||
```shell
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
2. Configure to use eos storage driver instead of default storage driver
|
||||
|
||||
* kill the home storage and data providers. we need to switch them to the eoshome driver:
|
||||
|
||||
```shell
|
||||
docker-compose exec ocis ./bin/ocis kill reva-storage-home
|
||||
docker-compose exec ocis ./bin/ocis kill reva-storage-home-data
|
||||
```
|
||||
|
||||
* restart them with the eoshome driver and a new layout:
|
||||
|
||||
```shell
|
||||
docker-compose exec -e REVA_STORAGE_EOS_LAYOUT="{{substr 0 1 .Username}}/{{.Username}}" -e REVA_STORAGE_HOME_DRIVER=eoshome -d ocis ./bin/ocis run reva-storage-home
|
||||
docker-compose exec -e REVA_STORAGE_EOS_LAYOUT="{{substr 0 1 .Username}}/{{.Username}}" -e REVA_STORAGE_HOME_DATA_DRIVER=eoshome -d ocis ./bin/ocis run reva-storage-home-data
|
||||
```
|
||||
|
||||
* restart the reva frontend with a new namespace (pointing to the eos storage provider) for the dav files endpoint
|
||||
|
||||
```shell
|
||||
docker-compose exec ocis ./bin/ocis kill reva-frontend
|
||||
docker-compose exec -e DAV_FILES_NAMESPACE="/eos/" -d ocis ./bin/ocis run reva-frontend
|
||||
```
|
||||
|
||||
* login with `einstein / relativity`, upload a file to einsteins home and verify the file is there using
|
||||
|
||||
```shell
|
||||
docker-compose exec ocis eos ls -l /eos/dockertest/reva/users/e/einstein/
|
||||
-rw-r--r-- 1 einstein users 10 Jul 1 15:24 newfile.txt
|
||||
```
|
||||
@@ -1,6 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
make build
|
||||
/start-ldap &
|
||||
|
||||
exec bin/ocis server
|
||||
@@ -1,17 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
LDAP_BINDDN=${LDAP_BINDDN:-cn=reva,ou=sysusers,dc=ocis,dc=test}
|
||||
LDAP_BINDPW=${LDAP_BINDPW:-reva}
|
||||
|
||||
echo "Waiting for EOS MGM"
|
||||
echo "until nc -z -w 3 $EOS_MGM_ALIAS 1094; do sleep 2; done;" > /wait-for-mgm
|
||||
chmod +x /wait-for-mgm
|
||||
|
||||
/wait-for-mgm;
|
||||
echo "----- [ocis] LDAP setup -----";
|
||||
authconfig --enableldap --enableldapauth --ldapserver=${EOS_LDAP_HOST} --ldapbasedn="dc=ocis,dc=test" --update;
|
||||
sed -i "s/#binddn cn=.*/binddn ${LDAP_BINDDN}/" /etc/nslcd.conf
|
||||
sed -i "s/#bindpw .*/bindpw ${LDAP_BINDPW}/" /etc/nslcd.conf
|
||||
# start in debug mode;
|
||||
|
||||
nslcd -d
|
||||
@@ -1,7 +0,0 @@
|
||||
FROM owncloud/eos-base:4.8.26
|
||||
RUN mkdir -p /usr/local/bin
|
||||
COPY dist/binaries/ocis-linux-amd64 /usr/local/bin/ocis
|
||||
RUN chmod +x /usr/local/bin/ocis
|
||||
|
||||
COPY docker/eos-ocis/setup /setup
|
||||
COPY docker/eos-ocis/entrypoint /entrypoint
|
||||
@@ -1,30 +0,0 @@
|
||||
# Docker image for oCIS running on eos
|
||||
|
||||
Image is based on [owncloud/eos-base](https://hub.docker.com/r/owncloud/eos-base) from [eos-stack](https://github.com/owncloud-docker/eos-stack)
|
||||
|
||||
## Build
|
||||
Build owncloud/ocis master branch
|
||||
```shell
|
||||
docker build -t owncloud/eos-ocis:latest .
|
||||
```
|
||||
|
||||
Or build a certain branch / tag
|
||||
```shell
|
||||
docker build -t owncloud/eos-ocis:1.0.0 --build-arg BRANCH=v1.0.0./eos-ocis
|
||||
```
|
||||
|
||||
## Publish
|
||||
```shell
|
||||
docker push owncloud/eos-ocis:latest
|
||||
```
|
||||
|
||||
## Maintainer
|
||||
|
||||
* [Felix Böhm](https://github.com/felixboehm)
|
||||
|
||||
## Disclaimer
|
||||
Use only for development or testing. Setup is not secured nor tested.
|
||||
|
||||
## Example Usage
|
||||
|
||||
See <https://github.com/owncloud-docker/compose-playground/tree/master/examples/eos-compose>
|
||||
@@ -1,17 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# todo: log all ocis services to stdout
|
||||
|
||||
echo "Waiting for EOS MGM"
|
||||
echo "until nc -z -w 3 $EOS_MGM_ALIAS 1094; do sleep 2; done;" > /wait-for-mgm
|
||||
chmod +x /wait-for-mgm
|
||||
mkdir -p /var/log/ocis
|
||||
|
||||
(/wait-for-mgm; /setup > /var/log/ocis/setup.log; cat /var/log/ocis/setup.log ) &
|
||||
|
||||
# TODO do we still need to precreate this folder?
|
||||
mkdir -p /var/tmp/reva
|
||||
|
||||
echo "----- [ocis] Starting oCIS -----"
|
||||
# todo start ocis as daemon not as root
|
||||
exec ocis server
|
||||
@@ -1,23 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -x
|
||||
|
||||
echo "----- [ocis] LDAP setup -----"
|
||||
authconfig --enableldap --enableldapauth --ldapserver=${EOS_LDAP_HOST} --ldapbasedn="dc=ocis,dc=test" --update
|
||||
sed -i "s/#binddn cn=.*/binddn ${LDAP_BINDDN}/" /etc/nslcd.conf
|
||||
sed -i "s/#bindpw .*/bindpw ${LDAP_BINDPW}/" /etc/nslcd.conf
|
||||
# start in debug mode
|
||||
nslcd -d &
|
||||
|
||||
# echo "----- [ocis] eos setup -----"
|
||||
# eos -r 0 0 -b vid set membership daemon -uids adm
|
||||
# eos -r 0 0 -b vid set membership daemon -gids adm
|
||||
# eos -r 0 0 -b vid set membership daemon +sudo
|
||||
# eos -r 0 0 -b vid set map -unix "<pwd>" vuid:0 vgid:0
|
||||
# # eos -r 0 0 -b vid add gateway ocis.testnet
|
||||
# eos -r 0 0 -b vid add gateway ocis
|
||||
|
||||
# todo start ocis as daemon not as root
|
||||
# eos -r 0 0 -b vid set membership root -uids adm
|
||||
# eos -r 0 0 -b vid set membership root -gids adm
|
||||
# eos -r 0 0 -b vid set membership root +sudo
|
||||
Reference in New Issue
Block a user