Unverified Commit a08b04a7 authored by michec81's avatar michec81 Committed by GitHub
Browse files

Merge pull request #136 from stefan-wolfsheimer/devel

Extend build system:
parents d2797da8 5f410cd5
#!/bin/bash
workdir=$(cd `dirname "${BASH_SOURCE[0]}"` && pwd)
YUM_SERVER='software@software.irodspoc-sara.surf-hosted.nl'
SSH_OPTIONS='-oStrictHostKeyChecking=no'
docker build $workdir/centos7_b2handle -t b2handle
docker run -v $workdir/centos7_b2handle/dist:/opt/B2HANDLE/dist b2handle
rpm=$workdir/centos7_b2handle/dist/b2handle-*.noarch.rpm
rpm_file=$( basename $rpm )
for REPO_NAME in irods-4.1.11 irods-4.1.12 irods-4.2.3 irods-4.2.4 irods-4.2.5 irods-4.2.6
do
ssh $SSH_OPTIONS $YUM_SERVER "mkdir -p /repos/CentOS/7/${REPO_NAME}/Packages/"
scp $SSH_OPTIONS $rpm $YUM_SERVER:/repos/CentOS/7/${REPO_NAME}/Packages/$rpm_file
ssh $SSH_OPTIONS $YUM_SERVER createrepo --update /repos/CentOS/7/${REPO_NAME}
done
FROM centos:7
RUN yum update -y && \
yum install -y python-setuptools \
rpm-build \
git
RUN git clone https://github.com/EUDAT-B2SAFE/B2HANDLE.git /opt/B2HANDLE
WORKDIR /opt/B2HANDLE
ADD build.sh /opt/B2HANDLE/build.sh
CMD /opt/B2HANDLE/build.sh
#!/bin/bash
rm /opt/B2HANDLE/dist/*.rpm
python setup.py bdist_rpm
*.rpm
*.tar.gz
\ No newline at end of file
......@@ -43,7 +43,10 @@ REPO_NAME=`repo_name $VERSION $GIT_URL $GIT_BRANCH `
set -e
set -x
BASEREPO_NAME=$( dirname $REPO_NAME )
ssh $SSH_OPTIONS $YUM_SERVER "mkdir -p /repos/CentOS/7/${REPO_NAME}/Packages/"
# create symlinks for 3rd party packages
ssh $SSH_OPTIONS $YUM_SERVER "/home/software/create_symlinks.sh /repos/CentOS/7/$BASEREPO_NAME"
scp $SSH_OPTIONS ./ci/RPMS/Centos/7/${REPO_NAME}/${RPM_PACKAGE} $YUM_SERVER:/repos/CentOS/7/${REPO_NAME}/Packages/
ssh $SSH_OPTIONS $YUM_SERVER createrepo --update /repos/CentOS/7/${REPO_NAME}
......@@ -21,7 +21,7 @@ configure the repo as root:
cat > /etc/yum.repos.d/surfsara-irods.repo <<EOF
[surfsara-irods]
name=Surfsara iRODS repo
baseurl=http://software.irodspoc-sara.surf-hosted.nl/CentOS/7/stefan-wolfsheimer/devel/irods-4.1.12
baseurl=https://software.irodspoc-sara.surf-hosted.nl/CentOS/7/irods-4.1.12
sslverify=0
gpgcheck=0
EOF
......@@ -33,10 +33,10 @@ Configure the yum repository for iRODS 4.2.6
configure the repo as root:
```bash
sudo cat > /etc/yum.repos.d/surfsara-irods.repo <<EOF
cat > /etc/yum.repos.d/surfsara-irods.repo <<EOF
[surfsara-irods]
name=Surfsara iRODS repo
baseurl=http://software.irodspoc-sara.surf-hosted.nl/CentOS/7/stefan-wolfsheimer/devel/irods-4.2.6
baseurl=https://software.irodspoc-sara.surf-hosted.nl/CentOS/7/irods-4.2.6
sslverify=0
gpgcheck=0
EOF
......@@ -45,7 +45,7 @@ EOF
Install pid-microservices for iRODS and B2SAFE
----------------------------------------------
```bash
sudo yum install msi-persistent-id irods-eudat-b2safe
sudo yum install msi-persistent-id b2handle irods-eudat-b2safe
```
After Installation / upgrade
......@@ -90,23 +90,7 @@ sudo su - $IRODS_SERVICE_ACCOUNT_NAME -s "/bin/bash" -c "cd /opt/eudat/b2safe/pa
DONE
## installation of B2HANDLE
The customers need to install the b2handle library on the b2safe system and
create public/private keypairs and certificates and get the public key binary
uploaded before the upgrades.
This entails following:
* Download the b2handle code from: https://github.com/EUDAT-B2SAFE/B2HANDLE
* Create an rpm and install it on the b2safe system. With the necessary
dependencies. See the github page:
```bash
python setup.py bdist_rpm
````
```bash
yum install <created_rpm in dist directory>
```
## confgiure B2HANDLE
* Ask the handle hosting service which user to use for a certificate.
* Create a private/public keypair and create a derived certificate as described
in http://eudat-b2safe.github.io/B2HANDLE/creatingclientcertificates.html.:
......@@ -120,3 +104,4 @@ in http://eudat-b2safe.github.io/B2HANDLE/creatingclientcertificates.html.:
```
* Ask hosting service which username/password to use for reverselooup.
* Test using curl
......@@ -12,7 +12,7 @@ BuildArch: noarch
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
#BuildRequires:
#Requires: irods-icat or irods-server
#Requires: msi-persistent-id b2handle
%define _whoami %(whoami)
%define _b2safehomepackaging %(pwd)
......@@ -169,6 +169,8 @@ fi
%changelog
* Wed Sep 19 2019 Stefan Wolfsheimer <stefan.wolfsheimer@surfsara.nl> 4.2.1
- add Requires
* Wed Jul 24 2019 Stefan Wolfsheimer <stefan.wolfsheimer@surfsara.nl> 4.2.1
- exclude python object files, fix install.json
* Tue Mar 26 2019 Robert Verkerk <robert.verkerk@surfsara.nl> 4.2.1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment