-
Notifications
You must be signed in to change notification settings - Fork 52
Add back zwe init shell code path #4429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: v3.x/staging
Are you sure you want to change the base?
Add back zwe init shell code path #4429
Conversation
Signed-off-by: 1000TurquoisePogs <[email protected]>
build 8257 FAILED. |
Signed-off-by: 1000TurquoisePogs <[email protected]>
build 8258 FAILED. |
Signed-off-by: Martin Zeithaml <[email protected]>
build 8264 SUCCEEDED. |
Test workflow 7029 is started. |
Signed-off-by: Martin Zeithaml <[email protected]>
build 8265 FAILED. |
bin/libs/common.sh
Outdated
# To determine which are used, we check if --generate is given (implies jcl) | ||
# If not, we check if zowe.setup.jcl.enabled is explicitly false. | ||
# If so, shell is used, otherwise jcl is used. | ||
check_jcl_init() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you code this (will fail on missing prefix on purpose):
zowe:
setup:
dataset:
prefix: ~
If will fail in javaScript code, but it should fail in shell - by default old code.
Also:
ZWE_CLI_PARAMETER_DATASET_PREFIX
is unique for oldzwe install
- The code should check if
FILE()
orPARMLIB()
was used -> only new code can handle this. - And I think, this is opposite of what we discussed: user must use
zowe.setup.jcl.enable=true
to request new code.
# Temporarily, the zwe init commands have old shell code and new jcl code paths available.
# To determine the code path:
# Config is uss file - more checks
# --generate - implies JCL code
# --dataset-prefix - parameter unique for zwe install & shell only
# zowe.setup.jcl.enable=false | undefined -> shell code
# zowe.setup.jcl.enable=true -> JCL code
# Not uss file
# FILE | PARMLIB | wrong input (we don't care here)
check_jcl_init() {
# If uss file
if [ -f "${ZWE_CLI_PARAMETER_CONFIG}" ]; then
enabled=$(read_yaml_configmgr "${ZWE_CLI_PARAMETER_CONFIG}" ".zowe.setup.jcl.enable")
if [ "${ZWE_CLI_PARAMETER_GENERATE}" = "true" ]; then
echo "true"
elif [ ! -z "${ZWE_CLI_PARAMETER_DATASET_PREFIX}" ]; then
echo "false"
elif [ "${enabled}" = "true" ]; then
echo "true"
else
echo "false"
fi
# Not uss file
else
echo "true"
fi
}
Signed-off-by: Martin Zeithaml <[email protected]>
build 8266 SUCCEEDED. |
Test workflow 7030 is started. |
bin/commands/init/apfauth/index.sh
Outdated
fi | ||
|
||
print_message "APF authorize ${ds}" | ||
apf_authorize_data_set "${ds}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Undocumented SDSF requirement: https://docs.zowe.org/stable/user-guide/systemrequirements-zos/#zos
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is also in ZWEIAPF2
...
bin/commands/init/stc/index.sh
Outdated
sed '/^..STEPLIB/c\ | ||
\//STEPLIB DD DSNAME='${authLoadlib}',DISP=SHR\ | ||
\// DD DSNAME='${authPluginLib}',DISP=SHR' | \ | ||
sed "s/^\/\/PARMLIB .*\$/\/\/PARMLIB DD DSNAME=${parmlib},DISP=SHR/" \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will not fit into the 80 chars:
----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
//PARMLIB DD DSNAME=----+----1----+----2----+----3----+----4----,DISP=SHR
DISP=SHR
must be on extra line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modified the sed's to try and accomplish this, worked in a test on the side
bin/commands/init/stc/index.sh
Outdated
print_debug "- Copy ${prefix}.${ZWE_PRIVATE_DS_SZWESAMP}(ZWESASTC) to ${tmpfile}" | ||
result=$(cat "//'${prefix}.${ZWE_PRIVATE_DS_SZWESAMP}(ZWESASTC)'" | \ | ||
sed '/^..STEPLIB/c\ | ||
\//STEPLIB DD DSNAME='${authLoadlib}',DISP=SHR\ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The sample ZWESASTC was changed, resulting into:
//STEPLIB DD DSNAME=ZOWE.PR#4429.SZWEAUTH,DISP=SHR
// DD DSNAME=ZOWE.PR#4429.PLUGINS,DISP=SHR
// DISP=SHR
// DD DSNAME={zowe.setup.dataset.authPluginLib},
// DISP=SHR
//SYSPRINT DD SYSOUT=*
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment as zwesistc
Signed-off-by: MarkAckert <[email protected]>
Signed-off-by: MarkAckert <[email protected]>
Signed-off-by: MarkAckert <[email protected]>
I've got the core workaround in place; the shell-only code is now branching to 3.2 versions of keyring and no keyring shell methods, and uses ZWEKRING/ZWENOKYR. Updated 8/4: Tested all 3 keyring options against RACF,ACF2,TSS, with and without I've adjusted the following:
Issues:
Other notes:
|
Signed-off-by: MarkAckert <[email protected]>
Signed-off-by: Martin Zeithaml <[email protected]>
Signed-off-by: Martin Zeithaml <[email protected]>
Signed-off-by: MarkAckert <[email protected]>
…keyring shell path Signed-off-by: MarkAckert <[email protected]>
Signed-off-by: MarkAckert <[email protected]>
This PR temporarily adds back zwe init shell code path as an option.
This option is toggled using the
zowe.setup.jcl.enable
option.It does not enhance the behavior of zwe init when disabled, but just exhibits 3.2-like behavior.