« ESXi : créer un vib manuellement sous linux » : différence entre les versions
Aller à la navigation
Aller à la recherche
Aucun résumé des modifications |
Aucun résumé des modifications |
||
Ligne 11 : | Ligne 11 : | ||
GZIP_SIZE=$(du --bytes smartctl | cut -f1) | GZIP_SIZE=$(du --bytes smartctl | cut -f1) | ||
touch sig.pkcs7 | touch sig.pkcs7 | ||
cat << EOF > descriptor.xml | |||
<vib version="5.0"><type>bootbank</type><name>smartctl</name><version>6.6-4433</version><vendor>smartmontools</vendor><summary>smartctl: SMART Tool</summary><description>Tool to display S.M.A.R.T data</description><release-date>2017-08-11T10:00:59.000000+00:00</release-date><urls/><relationships><depends></depends><conflicts/><replaces/><provides/><compatibleWith/></relationships><software-tags></software-tags><system-requires><maintenance-mode>false</maintenance-mode></system-requires><file-list><file>opt/smartmontools/smartctl</file></file-list><acceptance-level>community</acceptance-level><live-install-allowed>true</live-install-allowed><live-remove-allowed>true</live-remove-allowed><cimom-restart>false</cimom-restart><stateless-ready>true</stateless-ready><overlay>false</overlay><payloads><payload name="smartctl" type="tgz" size="666"><checksum checksum-type="sha-256">256000256</checksum><checksum checksum-type="sha-1" verify-process="gunzip">10001</checksum></payload></payloads> | |||
EOF | |||
</pre> | </pre> | ||
<pre> | <pre> |
Version du 12 août 2017 à 11:04
tar -xf smartmontools-6.6-0-20170808-r4433.linux-x86_64-static.tar.gz mkdir -p opt/smartmontools mv usr/local/sbin/smartctl opt/smartmontools/ rm -rf usr/ tar -cf smartctl opt/ TAR_SHA1=$(sha1sum smartctl | cut -d" " -f1) gzip smartctl mv smartctl.gz smartctl GZIP_SHA256=$(sha256sum smartctl | cut -d" " -f1) GZIP_SIZE=$(du --bytes smartctl | cut -f1) touch sig.pkcs7 cat << EOF > descriptor.xml <vib version="5.0"><type>bootbank</type><name>smartctl</name><version>6.6-4433</version><vendor>smartmontools</vendor><summary>smartctl: SMART Tool</summary><description>Tool to display S.M.A.R.T data</description><release-date>2017-08-11T10:00:59.000000+00:00</release-date><urls/><relationships><depends></depends><conflicts/><replaces/><provides/><compatibleWith/></relationships><software-tags></software-tags><system-requires><maintenance-mode>false</maintenance-mode></system-requires><file-list><file>opt/smartmontools/smartctl</file></file-list><acceptance-level>community</acceptance-level><live-install-allowed>true</live-install-allowed><live-remove-allowed>true</live-remove-allowed><cimom-restart>false</cimom-restart><stateless-ready>true</stateless-ready><overlay>false</overlay><payloads><payload name="smartctl" type="tgz" size="666"><checksum checksum-type="sha-256">256000256</checksum><checksum checksum-type="sha-1" verify-process="gunzip">10001</checksum></payload></payloads> EOF
sed -i s/666/$GZIP_SIZE/g descriptor.xml sed -i sed s/256000256/$GZIP_SHA256/g descriptor.xml sed -i s/10001/$TAR_SHA1/g descriptor.xml
ar -r smartctl-6.6-4433.x86_64.vib descriptor.xml sig.pkcs7 smartctl