copy-jdk-configs-4.0-2.el8 > 6 6_6 3!pQp)Tξ7]mtZ`aWD ]mtZ`߸t\ %?@9d6 }9:¸ fK'\JOYΙ(ױ=wOyqo4걥 vP w~}vXmLwDs>[Gc1BU{7 km&-FH+5hS(507Y" :9$l޶yo)FHSQ = Zvv+Cpd'92&cikmsɮ/l@>b7'2|/ńo@bX~Kc vb0q+e( <j0\ 'JIFG+_v>G r#9U豥9T~ضh1%8 {6HӛThH9ʹfhۣ4(OO]rA@7!: K41893b4aa5d37c19641013cddae65117ecd1000485e7ca4bcca1c2206f1285c765b0277b2ab4fbd273a5cfc51059167d974790fedd3!pQp)Tξ7]mtZ`aWD ]mtZ`e2"ϙ&:k dT cSyTH7ȬEn 1$+DK:% zb H`+ۇ6RE ݈zך"=s%)e R5RF.s#~mʾAr8^IK=uP3yHZ>< y~{d2wm(flN4Ji>`^>Qf>?oɅ:36_4 ==DODC*h?1Q׵{U:EMՒY s-Gy[)SP-86wBao ~.; Hz>G^/J#]*&SYƨ&z`or5}Xg,0H T9/޵oAޕ)'xh6g$*n4[yTgP8>pCHt?Hdd  =  -9\bl|    ` dt   (89@:GHIXY \,]<^bdJeOfRlTtlu|vwxy $GVGGHHHHHHH`Ccopy-jdk-configs4.02.el8JDKs configuration files copierUtility script to transfer JDKs configuration files between updates or for archiving. With script to fix incorrectly created rpmnew filesaCord1-prod-x86build002.svc.aws.rockylinux.orgMZKojiRockyBSDinfrastructure@rockylinux.orgUnspecifiedhttps://pagure.io/copy_jdk_configslinuxnoarch1ӁA큤`oB`oBaC`oB8a81cc8d2d07d525c97b56f4bf5d1457ce716b3c1de1e103e6acb4c9a1ffd5a463e5ebdd6bc16626b0b985f74d5de92c3dc06ab12f42ead06d353e15489064cf386eaf71633bf096e6c17471f50e867dabdf14d38a157ca27a0425dc583eb9ferootrootrootrootrootrootrootrootcopy-jdk-configs-4.0-2.el8.src.rpmcopy-jdk-configs@      /bin/bash/bin/shfindutilsluarpmlib(BuiltinLuaScripts)rpmlib(CompressedFileNames)rpmlib(FileDigests)rpmlib(PayloadFilesHavePrefix)rpmlib(PayloadIsXz)4.2.2-13.0.4-14.6.0-14.0-15.2-14.14.3`[`[___Z@Z@Z@Z@ZlZz@YB@YB@YYYx@X}@X}@X@XpXWWVVVqR@VUJiri Vanek - 4.0-2Jiri Vanek - 4.0-1Jiri Vanek - 3.7-3Jiri Vanek - 3.7-3Jiri Vanek - 3.7-2Jiri Vanek - 3.7-1Jiri Vanek - 3.3-12Jiri Vanek - 3.3-11Jiri Vanek - 3.3-10Jiri Vanek - 3.3-5Fedora Release Engineering - 3.3-3Jiri Vanek - 3.3-2Jiri Vanek - 3.3-1Jiri Vanek - 3.1-1Jiri Vanek - 3.0-1Fedora Release Engineering - 2.3-2Fedora Release Engineering - 2.2.3Fedora Release Engineering - 2.2.2Fedora Release Engineering - 2.1-2Jiri Vanek - 2.1-1Jiri Vanek - 2.0-1Jiri Vanek - 1.2-1Jiri Vanek - 1.1-5Fedora Release Engineering - 1.1-4Jiri Vanek - 1.1-3Jiri Vanek - 1.1-2Jiri Vanek - 1.1-1- commented out requires lua-posix, it was always commented out in el8, never in fedora. IDK - Resolves: rhbz#1953923- rebased to 4.0 - Resolves: rhbz#1953923- added link to http://hydra.brq.redhat.com:8080/view/c~j~c/#projectstatus - removed source check from test.yaml - added gating.yaml - Resolves: rhbz#1855374- added gatnig placeholder - Resolves: rhbz#1855374- added nss.fips.cfg to cared files - Resolves: rhbz#1855374- udpated to latst relase - configurable blacklist - listed all java keystores- blackidrs put on single line- added more files to balcklist based on oralce and ibm jdks- added javaws.policy and blacklist - fixed rhbz#1541838- fixed rhbz#1541838- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild- added another subdirs for policies files- handled new paths for policies files- moved to newest release 3.1 whcih conf and lib/security as directories- moved to newest release 3.0 whcih support linked configs- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild- updated to latest head- added "jre/lib/security/blacklisted.certs" to cared files- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild- moved to newest release 2.1- moved to new upstream at pagure.io - moved to newest release 2.0 - added new script of copy_jdk_configs_fixFiles.sh - copy_jdk_configs.lua aligned to it- updated to 1,3 which fixing nss minor issue- posttrans silenced, the error is appearing only in state, when there is nothing to copy- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild- pretrasn lua call now done in pcall (protected call) - also posttrans now always return 0- package now "installs" also during pretrans, so pretrasn scripts can use it - pretrasn "install" is removed in postrans- initial package4.0-2.el8copy_jdk_configs.luacopy_jdk_configs_fixFiles.shcopy-jdk-configsLICENSE/usr/libexec//usr/share/licenses//usr/share/licenses/copy-jdk-configs/-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m32 -march=x86-64 -mtune=generic -mfpmath=sse -mstackrealign -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protectioncpioxz2noarch-redhat-linux-gnua /usr/bin/lua script, ASCII text executableBourne-Again shell script, ASCII text executabledirectoryASCII textRfunction createPretransScript() -- the sript must be available during pretrans, so multiply it to tmp os.execute("mkdir -p /var/lib/rpm-state") temp_path="/var/lib/rpm-state/copy_jdk_configs.lua" -- print("generating " .. temp_path) file = io.open(temp_path, "w") file:write([[#!/usr/bin/lua -- rpm call -- debug=true lua -- copy_jdk_configs.lua --currentjvm "%{uniquesuffix %{nil}}" --jvmdir "%{_jvmdir %{nil}}" --origname "%{name}" --origjavaver "%{javaver}" --arch "%{_arch}" --test call -- debug=true lua -- copy_jdk_configs.lua --currentjvm "java-1.8.0-openjdk-1.8.0.65-3.b17.fc22.x86_64" --jvmdir "/usr/lib/jvm" --origname "java-1.8.0-openjdk" --origjavaver "1.8.0" --arch "x86_64" --jvmDestdir /home/jvanek/Desktop local M = {} if (os.getenv("debug") == "true") then debug = true; else debug = false; end local function debugOneLinePrint(string) if (debug) then print(string) end ; end function getPath(str, sep) sep = sep or '/' return str:match("(.*" .. sep .. ")") end function splitToTable(source, pattern) local i1 = string.gmatch(source, pattern) local l1 = {} for i in i1 do table.insert(l1, i) end return l1 end local function slurp(path) local f = io.open(path) local s = f:read("*a") f:close() return s end function trim(s) return (s:gsub("^%s*(.-)%s*$", "%1")) end local function dirWithParents(path) local s = "" local dirs = splitToTable(path, "[^/]+") for i, d in pairs(dirs) do if (i == #dirs) then break end s = s .. "/" .. d local stat2 = posix.stat(s, "type"); if (stat2 == nil) then debugOneLinePrint(s .. " does not exists, creating") if (not dry) then posix.mkdir(s) end else debugOneLinePrint(s .. " exists,not creating") end end end -- main function, -- formelry main body -- move to function resolved -- https://bugzilla.redhat.com/show_bug.cgi?id=1892224 -- for readability not indented, todo, indent once tuned function M.mainProgram(arg) debugOneLinePrint("cjc: lua debug on") local caredFiles = { "jre/lib/calendars.properties", "jre/lib/content-types.properties", "jre/lib/flavormap.properties", "jre/lib/logging.properties", "jre/lib/net.properties", "jre/lib/psfontj2d.properties", "jre/lib/sound.properties", "jre/lib/deployment.properties", "jre/lib/deployment.config", "jre/lib/security/US_export_policy.jar", "jre/lib/security/unlimited/US_export_policy.jar", "jre/lib/security/limited/US_export_policy.jar", "jre/lib/security/policy/unlimited/US_export_policy.jar", "jre/lib/security/policy/limited/US_export_policy.jar", "jre/lib/security/java.policy", "jre/lib/security/java.security", "jre/lib/security/local_policy.jar", "jre/lib/security/unlimited/local_policy.jar", "jre/lib/security/limited/local_policy.jar", "jre/lib/security/policy/unlimited/local_policy.jar", "jre/lib/security/policy/limited/local_policy.jar", "jre/lib/security/nss.cfg", "jre/lib/security/cacerts", "jre/lib/security/blacklisted.certs", "jre/lib/security/jssecacerts", "jre/lib/security/trusted.certs", "jre/lib/security/trusted.jssecerts", "jre/lib/security/trusted.clientcerts", "jre/lib/ext", "jre/lib/security/blacklist", "jre/lib/security/javaws.policy", "jre/lib/security/nss.fips.cfg", "lib/security", "conf", "lib/ext" } -- before import to allow run from spec if (arg[1] == "--list") then for i, file in pairs(caredFiles) do print(file) end return 0; end -- yum install lua-posix local posix = require "posix" -- the one we are installing local currentjvm = nil local jvmdir = nil local jvmDestdir = nil local origname = nil local origjavaver = nil local arch = nil local temp = nil; local dry = false; for i = 1, #arg, 2 do if (arg[i] == "--help" or arg[i] == "-h") then print("all but jvmDestdir and debug are mandatory") print(" --currentjvm") print(" NVRA of currently installed java") print(" --jvmdir") print(" Directory where to find this kind of virtual machine. Generally /usr/lib/jvm") print(" --origname") print(" convinient switch to determine jdk. Generally java-1.X.0-vendor") print(" --origjavaver") print(" convinient switch to determine jdk's version. Generally 1.X.0") print(" --arch") print(" convinient switch to determine jdk's arch") print(" --jvmDestdir") print(" Migration/testing switch. Target Mostly same as jvmdir, but you may wont to copy ouside it.") print(" --debug or $debug") print(" Enables printing out whats going on. true/false. False by default") print(" --temp") print(" optional file to save intermediate result - directory configs were copied from") print(" --dry") print(" true/fase if true, then no changes will be written to disk except one tmp file. False by default") print(" **** specil parasm ****") print(" --list") print(" if present on cmdline, list all cared files and exists") os.exit(0) end if (arg[i] == "--currentjvm") then currentjvm = arg[i + 1] end if (arg[i] == "--jvmdir") then jvmdir = arg[i + 1] end if (arg[i] == "--origname") then origname = arg[i + 1] end if (arg[i] == "--origjavaver") then origjavaver = arg[i + 1] end if (arg[i] == "--arch") then arch = arg[i + 1] end if (arg[i] == "--jvmDestdir") then jvmDestdir = arg[i + 1] end if (arg[i] == "--debug") then --no string, boolean, workaround if (arg[i + 1] == "true") then debug = true end end if (arg[i] == "--dry") then --no string, boolean, workaround if (arg[i + 1] == "true") then dry = true end end if (arg[i] == "--temp") then temp = arg[i + 1] end end if (jvmDestdir == nil) then jvmDestdir = jvmdir end if (debug) then print("--currentjvm:"); print(currentjvm); print("--jvmdir:"); print(jvmdir); print("--jvmDestdir:"); print(jvmDestdir); print("--origname:"); print(origname); print("--origjavaver:"); print(origjavaver); print("--arch:"); print(arch); print("--debug:"); print(debug); end --trasnform substitute names to lua patterns local name = string.gsub(string.gsub(origname, "%-", "%%-"), "%.", "%%.") local javaver = string.gsub(origjavaver, "%.", "%%.") local jvms = { } debugOneLinePrint("started") foundJvms = posix.dir(jvmdir); if (foundJvms == nil) then debugOneLinePrint("no, or nothing in " .. jvmdir .. " exit") return end debugOneLinePrint("found " .. #foundJvms .. " jvms") for i, p in pairs(foundJvms) do -- regex similar to %{_jvmdir}/%{name}-%{javaver}*%{_arch} bash command if (string.find(p, name .. "%-" .. javaver .. ".*" .. arch) ~= nil) then debugOneLinePrint("matched: " .. p) if (currentjvm == p) then debugOneLinePrint("this jdk is already installed. exiting lua script") return end ; if (string.match(p, ".*-debug$")) then print(p .. " matched but seems to be debug variant. Skipping") else table.insert(jvms, p) end else debugOneLinePrint("NOT matched: " .. p) end end if (#jvms <= 0) then debugOneLinePrint("no matching jdk in " .. jvmdir .. " exit") return end ; debugOneLinePrint("matched " .. #jvms .. " jdk in " .. jvmdir) --full names are like java-1.7.0-openjdk-1.7.0.60-2.4.5.1.fc20.x86_64 table.sort(jvms, function(a, b) -- version-sort -- split on non word: . - local l1 = splitToTable(a, "[^%.-]+") local l2 = splitToTable(b, "[^%.-]+") for x = 1, math.min(#l1, #l2) do local l1x = tonumber(l1[x]) local l2x = tonumber(l2[x]) if (l1x ~= nil and l2x ~= nil) then --if hunks are numbers, go with them if (l1x < l2x) then return true; end if (l1x > l2x) then return false; end else if (l1[x] < l2[x]) then return true; end if (l1[x] > l2[x]) then return false; end end -- if hunks are equals then move to another pair of hunks end return a < b end) if (debug) then print("sorted lsit of jvms") for i, file in pairs(jvms) do print(file) end end latestjvm = jvms[#jvms] if (temp ~= nil) then src = jvmdir .. "/" .. latestjvm debugOneLinePrint("temp declared as " .. temp .. " saving used dir of " .. src) file = io.open(temp, "w") file:write(src) file:close() end local readlinkOutput = os.tmpname() for i, file in pairs(caredFiles) do local SOURCE = jvmdir .. "/" .. latestjvm .. "/" .. file local DEST = jvmDestdir .. "/" .. currentjvm .. "/" .. file debugOneLinePrint("going to copy " .. SOURCE) debugOneLinePrint("to " .. DEST) local stat1 = posix.stat(SOURCE, "type"); if (stat1 ~= nil) then debugOneLinePrint(SOURCE .. " exists") dirWithParents(DEST) -- Copy with -a to keep everything intact local exe = "cp" .. " -ar " .. SOURCE .. " " .. DEST local linkExe = "readlink" .. " -f " .. SOURCE .. " > " .. readlinkOutput debugOneLinePrint("executing " .. linkExe) os.remove(readlinkOutput) os.execute(linkExe) local link = trim(slurp(readlinkOutput)) debugOneLinePrint(" ...link is " .. link) if (not ((link) == (SOURCE))) then debugOneLinePrint("WARNING link " .. link .. " where file " .. SOURCE .. " expected!") debugOneLinePrint("Will try to copy link target rather then link itself!") --replacing any NVRA by future NVRA (still execting to have NVRA for any multiple-installable targets -- lua stubbornly consider dash as inteval. Replacing by dot to match X-Y more correct as X.Y rather then not at all local linkDest = string.gsub(link, latestjvm:gsub("-", "."), currentjvm) debugOneLinePrint("attempting to copy " .. link .. " to " .. linkDest) if (link == linkDest) then debugOneLinePrint("Those are identical files! Nothing to do!") else local exe2 = "cp" .. " -ar " .. link .. " " .. linkDest dirWithParents(linkDest) debugOneLinePrint("executing " .. exe2) if (not dry) then os.execute(exe2) end end else debugOneLinePrint("executing " .. exe) if (not dry) then os.execute(exe) end end else debugOneLinePrint(SOURCE .. " does not exists") end end end --unindented main function if (arg == nil) then debugOneLinePrint("arg variable is nil, you have to call mainProgram manually") -- this can actually not be invoked, as the debug is set via arg else M.mainProgram(arg) end return M]]) file:close() end -- in netinst, the above call may fail. pcall should save instalation (as there is nothing to copy anyway) -- https://bugzilla.redhat.com/show_bug.cgi?id=1295701 -- todo, decide whether to check for {rpm_state_dir} and skip on not-existing, or keep creating if pcall(createPretransScript) then -- ok else -- print("Error running copy-jdk-configs pretrans.") end# remove file created in pretrans # echo "removing /var/lib/rpm-state/copy_jdk_configs.lua" || : rm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