Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
dbdf7f8
B2ACCESS new script that avoids the order of arguments
themiszamani Jul 17, 2018
df4ba85
Merge pull request #1 from themiszamani/devel
themiszamani Jul 17, 2018
65ab290
B2ACCESS new script that avoids the order of arguments
themiszamani Jul 17, 2018
9d35986
Merge pull request #2 from themiszamani/devel
themiszamani Jul 17, 2018
4d51237
B2ACCESS new script that avoids the order of arguments
themiszamani Jul 17, 2018
58e3ae3
Merge pull request #3 from themiszamani/devel
themiszamani Jul 17, 2018
52b2aa2
B2ACCESS new script that avoids the order of arguments
themiszamani Jul 17, 2018
f23f2ec
Merge pull request #4 from themiszamani/devel
themiszamani Jul 17, 2018
f915ccb
B2ACCESS new script that avoids the order of arguments
themiszamani Jul 17, 2018
5d7204c
Merge pull request #5 from themiszamani/devel
themiszamani Jul 17, 2018
b2104b7
DEVOPS-91 Add Jenkinsfile
kevangel79 Apr 6, 2020
a41c92d
Change project name
kevangel79 Apr 7, 2020
d2a0bff
Update Jenkinsfile
kevangel79 Apr 7, 2020
03880ad
Merge pull request #7 from kevangel79/feature/DEVOPS-91-Add-jenkinsfile
themiszamani Apr 9, 2020
c222cc8
Add cleanup workspace in each stage
kevangel79 May 8, 2020
058d3ba
Merge pull request #8 from kevangel79/feature/DEVOPS-137
themiszamani May 11, 2020
86b0ea5
Update nagios-plugins-eudat-b2access.spec
themiszamani Jan 24, 2022
5551da2
Update the spec file requirements
themiszamani Jan 24, 2022
3bb952f
Update nagios-plugins-eudat-b2access.spec
themiszamani Jan 24, 2022
d0e9088
Update Jenkinsfile
themiszamani Mar 15, 2022
541ded3
Update Makefile
themiszamani Mar 15, 2022
edfa1b8
Update Makefile
themiszamani Mar 15, 2022
0d3d18b
Update and rename nagios-plugins-eudat-b2access.spec to argo-probe-eu…
themiszamani Mar 15, 2022
2467fcd
remove a dependency
themiszamani Apr 6, 2022
bc6fb66
Put again the dependency
themiszamani Apr 6, 2022
4d2638b
Update argo-probe-eudat-b2access.spec
themiszamani Jul 31, 2024
80680a8
Update Jenkinsfile
themiszamani Jul 31, 2024
6f9c86d
Update check_b2access.py
themiszamani Jul 31, 2024
2b36a67
Merge pull request #12 from ARGOeu-Metrics/python3-rocky9
themiszamani Jul 31, 2024
ce3bdbf
Update check_b2access.py
themiszamani Jul 31, 2024
7ee512d
Update check_b2access_simple.py
themiszamani Jul 31, 2024
5494820
Merge pull request #14 from ARGOeu-Metrics/patch-python3
themiszamani Jul 31, 2024
be6de8a
Update check_b2access.py
themiszamani Jul 31, 2024
fc4dfb5
Merge pull request #15 from ARGOeu-Metrics/update-code
themiszamani Jul 31, 2024
d5b58d9
Update argo-probe-eudat-b2access.spec
themiszamani Jul 31, 2024
6fbfb8e
Update check_b2access.py
themiszamani Jul 31, 2024
55c89c0
Update check_b2access.py
themiszamani Jul 31, 2024
004b411
Update check_b2access.py
themiszamani Jul 31, 2024
7843913
Update check_b2access.py
themiszamani Jul 31, 2024
1a4ee7a
Update check_b2access.py
themiszamani Jul 31, 2024
882cc4d
Merge pull request #16 from ARGOeu-Metrics/errors-on-return
themiszamani Jul 31, 2024
0f9a6f3
Update check_b2access.py
themiszamani Aug 1, 2024
5a71772
Update check_b2access.py
themiszamani Aug 1, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
61 changes: 61 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
pipeline {
agent any
options {
checkoutToSubdirectory('argo-probe-eudat-b2access')
}
environment {
PROJECT_DIR="argo-probe-eudat-b2access"
GIT_COMMIT=sh(script: "cd ${WORKSPACE}/$PROJECT_DIR && git log -1 --format=\"%H\"",returnStdout: true).trim()
GIT_COMMIT_HASH=sh(script: "cd ${WORKSPACE}/$PROJECT_DIR && git log -1 --format=\"%H\" | cut -c1-9",returnStdout: true).trim()
GIT_COMMIT_DATE=sh(script: "date -d \"\$(cd ${WORKSPACE}/$PROJECT_DIR && git show -s --format=%ci ${GIT_COMMIT_HASH})\" \"+%Y%m%d%H%M%S\"",returnStdout: true).trim()

}
stages {
stage ('Build'){
parallel {

stage ('Build Rocky 9') {
agent {
docker {
image 'argo.registry:5000/epel-9-ams'
args '-u jenkins:jenkins'
}
}
steps {
echo 'Building Rocky 9 RPM...'
withCredentials(bindings: [sshUserPrivateKey(credentialsId: 'jenkins-rpm-repo', usernameVariable: 'REPOUSER', \
keyFileVariable: 'REPOKEY')]) {
sh "/home/jenkins/build-rpm.sh -w ${WORKSPACE} -b ${BRANCH_NAME} -d rocky9 -p ${PROJECT_DIR} -s ${REPOKEY}"

}
archiveArtifacts artifacts: '**/*.rpm', fingerprint: true
}
post {
always {
cleanWs()
}
}
}
}
}
}
post {
always {
cleanWs()
}
success {
script{
if ( env.BRANCH_NAME == 'master' || env.BRANCH_NAME == 'devel' ) {
slackSend( message: ":rocket: New version for <$BUILD_URL|$PROJECT_DIR>:$BRANCH_NAME Job: $JOB_NAME !")
}
}
}
failure {
script{
if ( env.BRANCH_NAME == 'master' || env.BRANCH_NAME == 'devel' ) {
slackSend( message: ":rain_cloud: Build Failed for <$BUILD_URL|$PROJECT_DIR>:$BRANCH_NAME Job: $JOB_NAME")
}
}
}
}
}
9 changes: 3 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
PKGNAME=nagios-plugins-eudat-b2access
PKGNAME=argo-probe-eudat-b2access
SPECFILE=${PKGNAME}.spec
FILES=check_b2access.py ${SPECFILE}
FILES=check_b2access.py check_b2access_simple.py ${SPECFILE}

PKGVERSION=$(shell grep -s '^Version:' $(SPECFILE) | sed -e 's/Version:\s*//')

srpm: dist
rpmbuild -ts --define='dist .el6' ${PKGNAME}-${PKGVERSION}.tar.gz

rpm: dist
rpmbuild -ta ${PKGNAME}-${PKGVERSION}.tar.gz

Expand All @@ -22,4 +19,4 @@ sources: dist

clean:
rm -rf ${PKGNAME}-${PKGVERSION}.tar.gz
rm -rf dist
rm -rf dist
Original file line number Diff line number Diff line change
Expand Up @@ -13,28 +13,25 @@
# See the License for the specific language governing permissions and
# limitations under the License.

Name: nagios-plugins-eudat-b2access
Version: 0.3
Name: argo-probe-eudat-b2access
Version: 0.5
Release: 1%{?dist}
Summary: Nagios B2ACCESS probes
Summary: Monitoring metrics for B2ACCESS
License: Apache License, Version 2.0
Packager: Shiraz Memon <a.memon@fz-juelich.de>

Source: %{name}-%{version}.tar.gz
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}

Requires: python
Requires: python-argparse
Requires: python-lxml
Requires: python-simplejson
Requires: python-defusedxml
Requires: python-httplib2
Requires: python-requests

Requires: python3
Requires: python3-requests
Requires: python3-oauthlib
Requires: python3-requests-oauthlib
Requires: python3-urllib3

%description
Nagios probes to check functionality of B2ACCESS Service
Monitoring metrics to check functionality of B2ACCESS Service

%prep
%setup -q
Expand All @@ -44,17 +41,25 @@ Nagios probes to check functionality of B2ACCESS Service

%install

install -d %{buildroot}/%{_libexecdir}/argo-monitoring/probes/%{probe_namespace}
install -m 755 check_b2access.py %{buildroot}/%{_libexecdir}/argo-monitoring/probes/%{probe_namespace}/check_b2access.py
install -d %{buildroot}/%{_libexecdir}/argo/probes/%{probe_namespace}
install -m 755 check_b2access.py %{buildroot}/%{_libexecdir}/argo/probes/%{probe_namespace}/check_b2access.py
install -m 755 check_b2access_simple.py %{buildroot}/%{_libexecdir}/argo/probes/%{probe_namespace}/check_b2access_simple.py

%files
%dir /%{_libexecdir}/argo-monitoring
%dir /%{_libexecdir}/argo-monitoring/probes/
%dir /%{_libexecdir}/argo-monitoring/probes/%{probe_namespace}
%dir /%{_libexecdir}/argo
%dir /%{_libexecdir}/argo/probes/
%dir /%{_libexecdir}/argo/probes/%{probe_namespace}

%attr(0755,root,root) /%{_libexecdir}/argo-monitoring/probes/%{probe_namespace}/check_b2access.py
%attr(0755,root,root) /%{_libexecdir}/argo/probes/%{probe_namespace}/check_b2access.py
%attr(0755,root,root) /%{_libexecdir}/argo/probes/%{probe_namespace}/check_b2access_simple.py

%changelog
* Mon Jul 14 2024 Marvin Winkens <m.winkens@fz-juelich.de> - 1.0-1
- Updated to python 3
* Tue Mar 15 2022 Themis Zamani <themiszamani@gmail.com> - 0.4-2
- Update the spec file requirements
* Mon Jan 24 2022 Themis Zamani <themiszamani@gmail.com> - 0.4-2
- Update the spec file requirements
* Tue Jun 05 2018 Shiraz Memon <a.memon@fz-juelich.de> - 0.4-1
- Adapted to Unity v2.x.x REST API
- More details in verbose mode
Expand All @@ -64,4 +69,4 @@ install -m 755 check_b2access.py %{buildroot}/%{_libexecdir}/argo-monitoring/pro
* Thu Sep 15 2016 Shiraz Memon <a.memon@fz-juelich.de> - 0.2-1
- Updated namespace and license information
* Thu Jul 28 2016 Shiraz Memon <a.memon@fz-juelich.de> - 0.1-1
- Initial version of the package
- Initial version of the package
Loading