From d99fce3e411c2e7491309adb932c786c6662d125 Mon Sep 17 00:00:00 2001 From: Davide Madrisan Date: Sat, 6 Jan 2024 07:12:55 +0100 Subject: [PATCH] package created using the webbuild interface [release 3.2.4-1mamba;Tue Apr 12 2016] --- README.md | 10 ++++++ mongo-tools.spec | 79 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 89 insertions(+) create mode 100644 mongo-tools.spec diff --git a/README.md b/README.md index 3111ee7..c27f8dc 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,12 @@ # mongo-tools +The MongoDB Tools: + - bsondump - display BSON files in a human-readable format + - mongoimport - Convert data from JSON, TSV or CSV and insert them into a collection + - mongoexport - Write an existing collection to CSV or JSON format + - mongodump/mongorestore - Dump MongoDB backups to disk in .BSON format, or restore them to a live database + - mongostat - Monitor live MongoDB servers, replica sets, or sharded clusters + - mongofiles - Read, write, delete, or update files in [GridFS](http://docs.mongodb.org/manual/core/gridfs/) + - mongooplog - Replay oplog entries between MongoDB servers + - mongotop - Monitor read/write activity on a mongo server + diff --git a/mongo-tools.spec b/mongo-tools.spec new file mode 100644 index 0000000..08e043e --- /dev/null +++ b/mongo-tools.spec @@ -0,0 +1,79 @@ +Name: mongo-tools +Version: 3.2.4 +Release: 1mamba +Summary: MongoDB Tools +Group: Applications/Databases +Vendor: openmamba +Distribution: openmamba +Packager: Davide Madrisan +URL: https://github.com/mongodb/mongo-tools +Source: https://github.com/mongodb/mongo-tools/archive/r%{version}.tar.gz +License: Apache License 2.0 +## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libgcc +BuildRequires: libgo-devel +## AUTOBUILDREQ-END +BuildRoot: %{_tmppath}/%{name}-%{version}-root + +%description +The MongoDB Tools: + - bsondump - display BSON files in a human-readable format + - mongoimport - Convert data from JSON, TSV or CSV and insert them into a collection + - mongoexport - Write an existing collection to CSV or JSON format + - mongodump/mongorestore - Dump MongoDB backups to disk in .BSON format, or restore them to a live database + - mongostat - Monitor live MongoDB servers, replica sets, or sharded clusters + - mongofiles - Read, write, delete, or update files in [GridFS](http://docs.mongodb.org/manual/core/gridfs/) + - mongooplog - Replay oplog entries between MongoDB servers + - mongotop - Monitor read/write activity on a mongo server + +%prep +%setup -q -n %{name}-r%{version} + +%build +mkdir -p src/github.com/mongodb +ln -s ../../../ src/github.com/mongodb/mongo-tools +export GOPATH=$(pwd):$(pwd)/vendor + +mkdir bin + +tools="\ +bsondump +mongoimport \ +mongoexport +mongodump +mongorestore +mongostat +mongofiles +mongooplog +mongotop" + +for tool in $tools; do + go build -o bin/$tool $tool/main/${tool}.go + # go build -o bin/$tool -tags ssl $tool/main/${tool}.go +done + +%install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" +install -d -p %{buildroot}%{_bindir} +install -p -m 0755 bin/* %{buildroot}%{_bindir} + +%clean +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +%files +%defattr(-,root,root) +%{_bindir}/bsondump +%{_bindir}/mongoimport +%{_bindir}/mongoexport +%{_bindir}/mongodump +%{_bindir}/mongorestore +%{_bindir}/mongostat +%{_bindir}/mongofiles +%{_bindir}/mongooplog +%{_bindir}/mongotop +%doc README.md + +%changelog +* Tue Apr 12 2016 Davide Madrisan 3.2.4-1mamba +- package created using the webbuild interface