--- /dev/null
+# vim: filetype=spec
+
+%define version @@@Version@@@
+%define builddir python@@@py_version_nodot@@@_dpx-puppettools-%{version}
+
+Name: dpx-puppettools
+Version: %{version}
+Release: @@@Release@@@%{?dist}
+Summary: CGI- and CLI-Scripts and modules for admin tasks on DPX Puppet servers
+
+Group: Development/Languages/Python
+License: AGPLv3
+Distribution: Frank Brehm
+URL: https://git.pixelpark.com/ppadmin/puppet-tools
+Source0: dpx-puppettools.%{version}.tar.gz
+
+BuildRequires: gettext
+BuildRequires: python@@@py_version_nodot@@@
+BuildRequires: python@@@py_version_nodot@@@-libs
+BuildRequires: python@@@py_version_nodot@@@-devel
+BuildRequires: python@@@py_version_nodot@@@-setuptools
+BuildRequires: python@@@py_version_nodot@@@-babel
+BuildRequires: python@@@py_version_nodot@@@-pytz
+BuildRequires: python@@@py_version_nodot@@@-six
+BuildRequires: python@@@py_version_nodot@@@-fb-logging
+BuildRequires: python@@@py_version_nodot@@@-fb-tools >= 2.1.0
+Requires: python@@@py_version_nodot@@@
+Requires: python@@@py_version_nodot@@@-libs
+Requires: python@@@py_version_nodot@@@-babel
+Requires: python@@@py_version_nodot@@@-psutil
+Requires: python@@@py_version_nodot@@@-pytz
+Requires: python@@@py_version_nodot@@@-requests
+Requires: python@@@py_version_nodot@@@-six
+Requires: python@@@py_version_nodot@@@-fb-logging
+Requires: python@@@py_version_nodot@@@-fb-tools >= 2.1.0
+BuildArch: noarch
+
+%description
+This is a collection of CLI and CGI scripts and their appropriate libraries,
+which should help on administrating and maintaining Puppet servers (Compilers, CAs and PuppetDB).
+
+This package is intended to use with Python@@@py_version_nodot@@@.
+
+In this package are contained the following scripts:
+ * get-forge-module
+ * update-puppet-env
+
+%prep
+%setup -n %{builddir}
+
+%build
+cd ../%{builddir}
+python@@@py_version_dot@@@ setup.py build
+
+%install
+cd ../%{builddir}
+echo "Buildroot: %{buildroot}"
+python@@@py_version_dot@@@ setup.py install --prefix=%{_prefix} --root=%{buildroot}
+
+%files
+%defattr(-,root,root,-)
+%license LICENSE
+%doc LICENSE README.md requirements.txt debian/changelog
+%dir /etc/pixelpark
+%config /etc/pixelpark/dns-deploy-zones.ini.default
+%{_bindir}/*
+%{python3_sitelib}/*
+%dir /var/log/dpx-puppet-tools
+%dir /var/lib/dpx-puppet-tools
+%dir /usr/libexec/dpx-puppet-tools
+/usr/libexec/dpx-puppet-tools/*
+
+%changelog