]> repo.cephalix.eu Git - MsOffice2016StandardKMS.git/commitdiff
Initial version
authorCEPHALIX GIT ADMIN <git@cephalix.eu>
Wed, 17 Oct 2018 18:47:18 +0000 (20:47 +0200)
committerCEPHALIX GIT ADMIN <git@cephalix.eu>
Wed, 17 Oct 2018 18:47:18 +0000 (20:47 +0200)
LICENSE [new file with mode: 0644]
Makefile [new file with mode: 0644]
MsOffice2016StandardKMS.sls [new file with mode: 0644]
RELEASE [new file with mode: 0644]
VERSION [new file with mode: 0644]
oss-pkg-MsOffice2016StandardKMS.spec [new file with mode: 0644]
repo-ng/init.sls [new file with mode: 0644]
repo-ng/x64/install.xml [new file with mode: 0755]
repo-ng/x64/uninstall.xml [new file with mode: 0755]
repo-ng/x86/install.xml [new file with mode: 0755]
repo-ng/x86/uninstall.xml [new file with mode: 0755]

diff --git a/LICENSE b/LICENSE
new file mode 100644 (file)
index 0000000..c70fc0d
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1 @@
+Copyright (c) 2017 Peter Varkoly and Helmuth Varkoly Nürnberg. All rights reserverd.
\ No newline at end of file
diff --git a/Makefile b/Makefile
new file mode 100644 (file)
index 0000000..50c588a
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,29 @@
+PACKAGE         = $(shell basename `pwd` )
+DESTDIR         = /
+REPO            = /srv/www/repo/salt-packages/
+VERSION         = $(shell cat VERSION )
+RELEASE         = $(shell cat RELEASE )
+NRELEASE        = $(shell echo $(RELEASE) + 1 | bc )
+YEAR           = $(shell date +%Y )
+
+
+package:
+       if [ ! -e oss-pkg-$(PACKAGE).spec ]; then cp ../template/package.spec oss-pkg-$(PACKAGE).spec; fi
+       sed -i s/VERSION/$(VERSION)/g  oss-pkg-$(PACKAGE).spec
+       sed -i s/RELEASE/$(NRELEASE)/g oss-pkg-$(PACKAGE).spec
+       sed -i s/PACKAGE/$(PACKAGE)/g  oss-pkg-$(PACKAGE).spec
+       sed -i s/YEAR/$(YEAR)/g        oss-pkg-$(PACKAGE).spec
+       mkdir -p oss-pkg-$(PACKAGE)
+       if [ ! -e $(PACKAGE).sls ];  then cp ../template/template.sls $(PACKAGE).sls; fi
+       sed s/PACKAGE/$(PACKAGE)/g  $(PACKAGE).sls > oss-pkg-$(PACKAGE)/$(PACKAGE).sls
+       if [ -d repo-ng ]; then ln -s ../repo-ng/ oss-pkg-$(PACKAGE)/repo-ng; fi
+       tar hjcvpf oss-pkg-$(PACKAGE).tar.bz2 oss-pkg-$(PACKAGE)  
+       rm -rf oss-pkg-$(PACKAGE)
+       mv  oss-pkg-$(PACKAGE).tar.bz2  /usr/src/packages/SOURCES/
+       rpmbuild -bb oss-pkg-$(PACKAGE).spec
+       mv /usr/src/packages/RPMS/noarch/oss-pkg-$(PACKAGE)-$(VERSION)-$(NRELEASE).noarch.rpm $(REPO)/noarch
+       echo $(NRELEASE) > RELEASE
+       git commit -a -m "New release"
+       git push
+
+
diff --git a/MsOffice2016StandardKMS.sls b/MsOffice2016StandardKMS.sls
new file mode 100644 (file)
index 0000000..044c03a
--- /dev/null
@@ -0,0 +1,30 @@
+###############################################################################
+# SLS: PACKAGE
+# Copyright (c) 2017 Helmuth Varkoly, Nuermberg, Germany.
+# All rights reserved.
+#
+# Author:               Helmuth Varkoly
+#
+# Description:          SLS to use with OSS's softwaremanagement              
+###############################################################################
+{% if grains['cpuarch'] == 'AMD64' %}
+{% set ARCH = "x64" %}
+{% else %}
+{% set ARCH = "x86" %}
+{% endif %}
+
+PACKAGE:
+  pkg:
+    - installed
+
+activateKMS:
+  cmd.run:
+    - onchanges:
+      - pkg: MsOffice2016StandardKMS
+    {% if ARCH == 'x64' %}
+    - name : 'cscript "%PROGRAMFILES(x86)%\Microsoft Office\Office16\OSPP.VBS" /sethst:#KMS_SERVER_HOST_NAME#'
+    - name : 'cscript "%PROGRAMFILES(x86)%\Microsoft Office\Office16\OSPP.VBS" /act'
+    {% else %}
+    - name : 'cscript "%PROGRAMFILES%\Microsoft Office\Office16\OSPP.VBS" /sethst:#KMS_SERVER_HOST_NAME#'
+    - name : 'cscript "%PROGRAMFILES%\Microsoft Office\Office16\OSPP.VBS" /act'
+    {% endif %}
diff --git a/RELEASE b/RELEASE
new file mode 100644 (file)
index 0000000..c227083
--- /dev/null
+++ b/RELEASE
@@ -0,0 +1 @@
+0
\ No newline at end of file
diff --git a/VERSION b/VERSION
new file mode 100644 (file)
index 0000000..0d68f8a
--- /dev/null
+++ b/VERSION
@@ -0,0 +1 @@
+16.0
diff --git a/oss-pkg-MsOffice2016StandardKMS.spec b/oss-pkg-MsOffice2016StandardKMS.spec
new file mode 100644 (file)
index 0000000..079b12d
--- /dev/null
@@ -0,0 +1,58 @@
+#
+# Spec file for PACKAGE
+# Copyright (c) YEAR Helmuth Varkoly and Peter Varkoly Nuremberg, Germany.  All rights reserved.
+#
+
+Name:         oss-pkg-PACKAGE
+Summary:      Package to install PACKAGE on OSS-Clients
+Version:      VERSION
+Release:      RELEASE
+License:      GPL-2.0
+Vendor:       Peter Varkoly and Helmuth Varkoly
+Packager:     peter@varkoly.de
+Group:        Productivity/
+Source:       %{name}.tar.bz2
+BuildArch:    noarch
+BuildRequires:unzip
+#Requires:     
+Requires:     filesystem
+PreReq:       salt-master
+PreReq:       %fillup_prereq
+BuildRoot:    %{_tmppath}/%{name}-%{version}-build
+
+%description
+Package to install PACKAGE on OSS-Clients
+
+Authors:
+--------
+        helmuth@varkoly.de
+        peter@varkoly.de
+
+
+%prep
+%setup -n %{name}
+
+%build
+
+%install
+
+mkdir -p %{buildroot}/srv/salt/win/repo-ng/PACKAGE
+mkdir -p %{buildroot}/srv/salt/packages/
+cp PACKAGE.sls  %{buildroot}/srv/salt/packages/
+cp -a repo-ng/* %{buildroot}/srv/salt/win/repo-ng/PACKAGE
+
+%clean
+rm -rf %{buildroot}
+
+%pre
+
+%post
+
+/usr/sbin/oss_api.sh POST 'softwares/add' '{"name":"PACKAGE","manually":false,"description":"PACKAGE","softwareVersions":[{"version":"VERSION"}]}'
+
+%files
+%defattr(644,root,root)
+/srv/salt/win/repo-ng/PACKAGE
+/srv/salt/packages/PACKAGE.sls
+
+
diff --git a/repo-ng/init.sls b/repo-ng/init.sls
new file mode 100644 (file)
index 0000000..0d50bbd
--- /dev/null
@@ -0,0 +1,34 @@
+###############################################################################
+# SLS: MsOffice2016StandardKMS
+# Copyright (c) 2017 Helmuth Varkoly, Nuermberg, Germany.
+# All rights reserved.
+#
+# Authors:              Helmuth Varkoly
+#
+# Description:          Package SLS
+###############################################################################
+
+{% if grains['cpuarch'] == 'AMD64' %}
+{% set ARCH = "x64" %}
+{% else %}
+{% set ARCH = "x86" %}
+{% endif %}
+
+MsOffice2016StandardKMS:
+  '16.0':
+    full_name: 'Mircosoft Office Standard 2016'
+    {% if ARCH == 'x64' %}
+    installer: salt://win/repo-ng/MsOffice2016StandardKMS/x64/setup.exe
+    uninstaller: salt://win/repo-ng/MsOffice2016StandardKMS/x64/setup.exe
+    install_flags: '/config  C:\salt\var\cache\salt\minion\files\base\win\repo\MsOffice2016StandardKMS\x64\install.xml'
+    uninstall_flags: '/uninstall STANDARD /config  C:\salt\var\cache\salt\minion\files\base\win\repo\MsOffice2016StandardKMS\x64\uninstall.xml'
+    {% else %}
+    installer: salt://win/repo-ng/MsOffice2016StandardKMS/x86/setup.exe
+    uninstaller: salt://win/repo-ng/MsOffice2016StandardKMS/x86/setup.exe
+    install_flags: '/config  C:\salt\var\cache\salt\minion\files\base\win\repo\MsOffice2016StandardKMS\x86\install.xml'
+    uninstall_flags: '/uninstall STANDARD /config  C:\salt\var\cache\salt\minion\files\base\win\repo\MsOffice2016StandardKMS\x86\uninstall.xml'
+    {% endif %}
+    msiexec: False
+    locale: de_DE
+    reboot: False
+    cache_dir: True
diff --git a/repo-ng/x64/install.xml b/repo-ng/x64/install.xml
new file mode 100755 (executable)
index 0000000..b257da9
--- /dev/null
@@ -0,0 +1,12 @@
+<Configuration Product="MsOffice2016StandardDEx64KMS">\r
+       <Display Level="none" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />\r
+       <Logging Type="standard" Path="C:\salt\var\log" Template="MsOffice2016StandardDEx64KMS_inst.log"/>\r
+       <OptionState Id="ACCESSFiles"  State="Local"  Children="force" /><!-- Access -->\r
+       <OptionState Id="EXCELFiles"   State="Local"  Children="force" /><!-- Excel -->\r
+       <OptionState Id="OneNoteFiles" State="Local" Children="force" /><!-- OneNote -->\r
+       <OptionState Id="OUTLOOKFiles" State="Local"  Children="force" /><!-- Outlook -->\r
+       <OptionState Id="PPTFiles"     State="Local"  Children="force" /><!-- Powerpoint -->\r
+       <OptionState Id="PubPrimary"   State="Local"  Children="force" /><!-- Publisher -->\r
+       <OptionState Id="WORDFiles"    State="Local"  Children="force" /><!-- Word -->\r
+       <!-- <Setting Id="Reboot" Value="IfNeeded" /> --> \r
+</Configuration>\r
diff --git a/repo-ng/x64/uninstall.xml b/repo-ng/x64/uninstall.xml
new file mode 100755 (executable)
index 0000000..d61f57a
--- /dev/null
@@ -0,0 +1,5 @@
+<Configuration Product="MsOffice2016StandardDEx64KMS">\r
+       <Display Level="none" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />\r
+       <Logging Type="standard" Path="C:\salt\var\log" Template="MsOffice2016StandardDEx64KMS_uninst.log" /> \r
+       <Setting Id="SETUP_REBOOT" Value="NEVER" />\r
+ </Configuration>\r
diff --git a/repo-ng/x86/install.xml b/repo-ng/x86/install.xml
new file mode 100755 (executable)
index 0000000..e9b77d3
--- /dev/null
@@ -0,0 +1,12 @@
+<Configuration Product="MsOffice2016StandardDEx86KMS">\r
+       <Display Level="none" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />\r
+       <Logging Type="standard" Path="C:\salt\var\log" Template="MsOffice2016StandardDEx86KMS_inst.log"/>\r
+       <OptionState Id="ACCESSFiles"  State="Local"  Children="force" /><!-- Access -->\r
+       <OptionState Id="EXCELFiles"   State="Local"  Children="force" /><!-- Excel -->\r
+       <OptionState Id="OneNoteFiles" State="Local" Children="force" /><!-- OneNote -->\r
+       <OptionState Id="OUTLOOKFiles" State="Local"  Children="force" /><!-- Outlook -->\r
+       <OptionState Id="PPTFiles"     State="Local"  Children="force" /><!-- Powerpoint -->\r
+       <OptionState Id="PubPrimary"   State="Local"  Children="force" /><!-- Publisher -->\r
+       <OptionState Id="WORDFiles"    State="Local"  Children="force" /><!-- Word -->\r
+       <!-- <Setting Id="Reboot" Value="IfNeeded" /> --> \r
+</Configuration>\r
diff --git a/repo-ng/x86/uninstall.xml b/repo-ng/x86/uninstall.xml
new file mode 100755 (executable)
index 0000000..3f4414a
--- /dev/null
@@ -0,0 +1,5 @@
+<Configuration Product="MsOffice2016StandardDEx86KMS">\r
+       <Display Level="none" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />\r
+       <Logging Type="standard" Path="C:\salt\var\log" Template="MsOffice2016StandardDEx86KMS_uninst.log" /> \r
+       <Setting Id="SETUP_REBOOT" Value="NEVER" />\r
+ </Configuration>\r