mirror of https://github.com/ceph/go-ceph
ci: fixup ci for jewel and kraken
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
This commit is contained in:
parent
dba6a108d6
commit
fd5c141175
28
.travis.yml
28
.travis.yml
|
@ -1,30 +1,26 @@
|
||||||
|
dist: trusty
|
||||||
|
sudo: required
|
||||||
|
|
||||||
language: go
|
language: go
|
||||||
|
|
||||||
branches:
|
branches:
|
||||||
except:
|
except:
|
||||||
- gh-pages
|
- gh-pages
|
||||||
|
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- env: CEPH_RELEASE=jewel
|
||||||
|
- env: CEPH_RELEASE=kraken
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
- ssh-keygen -f $HOME/.ssh/id_rsa -t rsa -N ''
|
- sudo apt-get update
|
||||||
- cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
|
- ci/before_install.sh
|
||||||
- chmod 600 ~/.ssh/authorized_keys
|
|
||||||
- sudo pip install ceph-deploy
|
|
||||||
- ceph-deploy install --release giant `hostname`
|
|
||||||
- ceph-deploy pkg --install librados-dev `hostname`
|
|
||||||
- ceph-deploy pkg --install librbd-dev `hostname`
|
|
||||||
- ceph-deploy pkg --install libcephfs-dev `hostname`
|
|
||||||
- bash ci/micro-osd.sh /tmp/micro-ceph
|
- bash ci/micro-osd.sh /tmp/micro-ceph
|
||||||
- export CEPH_CONF=/tmp/micro-ceph/ceph.conf
|
- export CEPH_CONF=/tmp/micro-ceph/ceph.conf
|
||||||
- ceph status
|
- ceph status
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- go get -t -v ./...
|
- go get -t -v ./...
|
||||||
- go test -v ./...
|
- go list ./...
|
||||||
|
- go test -v $(go list ./... | grep -v cephfs)
|
||||||
- go fmt ./...
|
- go fmt ./...
|
||||||
|
|
||||||
notifications:
|
|
||||||
recipients:
|
|
||||||
- noahwatkins@gmail.com
|
|
||||||
email:
|
|
||||||
on_success: always
|
|
||||||
on_failure: always
|
|
||||||
|
|
|
@ -0,0 +1,27 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
|
sudo apt-get install -y python-virtualenv
|
||||||
|
|
||||||
|
# ceph-deploy and ceph
|
||||||
|
|
||||||
|
WORKDIR=$HOME/workdir
|
||||||
|
mkdir $WORKDIR
|
||||||
|
pushd $WORKDIR
|
||||||
|
|
||||||
|
ssh-keygen -f $HOME/.ssh/id_rsa -t rsa -N ''
|
||||||
|
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
|
||||||
|
chmod 600 ~/.ssh/authorized_keys
|
||||||
|
|
||||||
|
git clone git://github.com/ceph/ceph-deploy
|
||||||
|
pushd ceph-deploy
|
||||||
|
./bootstrap
|
||||||
|
./ceph-deploy install --release ${CEPH_RELEASE} `hostname`
|
||||||
|
./ceph-deploy pkg --install librados-dev `hostname`
|
||||||
|
./ceph-deploy pkg --install librbd-dev `hostname`
|
||||||
|
./ceph-deploy pkg --install libcephfs-dev `hostname`
|
||||||
|
popd # ceph-deploy
|
||||||
|
|
||||||
|
popd # workdir
|
|
@ -100,10 +100,19 @@ ceph osd pool create cephfs_metadata 8
|
||||||
ceph fs new cephfs cephfs_metadata cephfs_data
|
ceph fs new cephfs cephfs_metadata cephfs_data
|
||||||
ceph-mds -i a
|
ceph-mds -i a
|
||||||
|
|
||||||
|
export CEPH_CONF="${DIR}/ceph.conf"
|
||||||
|
|
||||||
|
while true; do
|
||||||
|
if ceph status | tee /dev/tty | grep -q HEALTH_OK; then
|
||||||
|
if ! ceph status | grep -q creating &> /dev/null; then
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
# check that it works
|
# check that it works
|
||||||
rados --pool rbd put group /etc/group
|
rados --pool rbd put group /etc/group
|
||||||
rados --pool rbd get group ${DIR}/group
|
rados --pool rbd get group ${DIR}/group
|
||||||
diff /etc/group ${DIR}/group
|
diff /etc/group ${DIR}/group
|
||||||
ceph osd tree
|
ceph osd tree
|
||||||
|
|
||||||
export CEPH_CONF="${DIR}/ceph.conf"
|
|
||||||
|
|
Loading…
Reference in New Issue