Skip to content

Commit

Permalink
Merge branch 'feature/v3/jcl' into user/markackert/zwe-tests
Browse files Browse the repository at this point in the history
Signed-off-by: MarkAckert <[email protected]>
  • Loading branch information
MarkAckert committed Jun 4, 2024
2 parents 8e016a7 + bc5de91 commit 7679de3
Show file tree
Hide file tree
Showing 20 changed files with 204 additions and 197 deletions.
12 changes: 8 additions & 4 deletions bin/commands/init/apfauth/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,17 @@ export function execute() {
common.printTrace(` * Output:`);
common.printTrace(stringlib.paddingLeft(jclContent.out, " "));

if (!result1.smsManaged) {
if (result1.rc === 0 && !result1.smsManaged) {
let result3 = zosDs.getDatasetVolume(ZOWE_CONFIG.zowe.setup.dataset.authLoadlib);
jclContent.out = jclContent.out.replace("export LOADLOC=SMS", `export LOADLOC="VOLUME=${result3.volume}"`);
if (result3.volume) {
jclContent.out = jclContent.out.replace("export LOADLOC=SMS", `export LOADLOC="VOLUME=${result3.volume}"`);
}
}
if (!result2.smsManaged) {
if (result2.rc === 0 && !result2.smsManaged) {
let result4 = zosDs.getDatasetVolume(ZOWE_CONFIG.zowe.setup.dataset.authPluginLib);
jclContent.out = jclContent.out.replace("export PLUGLOC=SMS", `export PLUGLOC="VOLUME=${result4.volume}"`);
if (result4.volume) {
jclContent.out = jclContent.out.replace("export PLUGLOC=SMS", `export PLUGLOC="VOLUME=${result4.volume}"`);
}
}

xplatform.storeFileUTF8(tmpfile, xplatform.AUTO_DETECT, jclContent.out);
Expand Down
1 change: 1 addition & 0 deletions bin/libs/configmgr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,7 @@ function getMemberNameFromConfigPath(configPath: string): string|undefined {
const memberEnd = configPath.indexOf('))', memberStart+1);
if (memberEnd == -1) {
console.log(`Error: malformed PARMLIB syntax for ${configPath}. Must use syntax PARMLIB(dataset.name(member))`);
return undefined;
}
const thisMember = configPath.substring(memberStart+1, memberEnd);
if (!member) {
Expand Down
36 changes: 19 additions & 17 deletions files/SZWEEXEC/ZWEGEN00
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
================================================================================
*/

parse arg operation verbosity
parse arg operation verbosity

!verbose = COMPARE(verbosity, 'noverbose')

Expand Down Expand Up @@ -157,7 +157,7 @@ CVTRAC_VAL = STORAGE(CVTRAC_ADDR, 4)

ringType = 0

/* attempt to handle getting only 1 keyring jcl
/* attempt to handle getting only 1 keyring jcl
if WORDINDEX(CFG.zowe.setup.certificate.type, 'JCE') > 0 then do
if LENGTH(CFG.zowe.setup.certificate.keyring.connect) > 0 then do
say 'connect exists, it is 'CFG.zowe.setup.certificate.keyring.connect'.'
Expand All @@ -172,9 +172,9 @@ if WORDINDEX(CFG.zowe.setup.certificate.type, 'JCE') > 0 then do
ringType = 1
end
else do
say 'pkcs12 to be used'
say 'pkcs12 to be used'
end
*/
*/

if COMPARE('RCVT', CVTRAC_VAL) = 0 then do
x = DeleteDataSet(jclCopy'(ZWEIKRA1)')
Expand Down Expand Up @@ -210,7 +210,7 @@ if COMPARE('ACF2', CVTRAC_VAL) = 0 then do
x = DeleteDataSet(jclCopy'(ZWEIKRT3)')
x = DeleteDataSet(jclCopy'(ZWEIKRR1)')
x = DeleteDataSet(jclCopy'(ZWEIKRR2)')
x = DeleteDataSet(jclCopy'(ZWEIKRR3)')
x = DeleteDataSet(jclCopy'(ZWEIKRR3)')
x = DeleteDataSet(jclCopy'(ZWEIRAC)')
x = DeleteDataSet(jclCopy'(ZWEIRACZ)')
x = DeleteDataSet(jclCopy'(ZWEITSS)')
Expand Down Expand Up @@ -275,19 +275,21 @@ do i = 1 to members.0
len = lastChar - firstChar + 1
if len > 0 then do
sub = SUBSTR(!contentToRead.j, firstChar, len)
call Print 'Substitution found for' sub'.'
isFound = 0
do n = 1 to members.i.substitutions.0
if COMPARE(members.i.substitutions.n, sub) = 0 then do
call Print 'Substitution 'sub' already noted. Skipping.'
isFound = 1
leave
if len = length(strip(sub)) then do
call Print 'Substitution found for' sub'.'
isFound = 0
do n = 1 to members.i.substitutions.0
if COMPARE(members.i.substitutions.n, sub) = 0 then do
call Print 'Substitution 'sub' already noted. Skipping.'
isFound = 1
leave
end
end
if isFound <> 1 then do
k = members.i.substitutions.0 + 1
members.i.substitutions.k = sub
members.i.substitutions.0 = k
end
end
if isFound <> 1 then do
k = members.i.substitutions.0 + 1
members.i.substitutions.k = sub
members.i.substitutions.0 = k
end
end
if lastChar < 0 then do
Expand Down
56 changes: 28 additions & 28 deletions files/SZWESAMP/ZWECSRVS
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
//ZWECSRVS JOB
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*********************************************************************
//*
//* This JCL removes the VSAM data set for the Caching Service.
//*
//*
//* CAUTION: This is neither a JCL procedure nor a complete job.
//* Before using this JCL, you will have to make the following
//* modifications:
//*
//* 1) Add job name and job parameters to the JOB statement, to
//* meet your system requirements.
//*
//********************************************************************
//RMVSAM EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=A
//SYSTSIN DD *
//ZWECSRVS JOB
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*********************************************************************
//*
//* This JCL removes the VSAM data set for the Caching Service.
//*
//*
//* CAUTION: This is neither a JCL procedure nor a complete job.
//* Before using this JCL, you will have to make the following
//* modifications:
//*
//* 1) Add job name and job parameters to the JOB statement, to
//* meet your system requirements.
//*
//********************************************************************
//RMVSAM EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=A
//SYSTSIN DD *
DELETE '{zowe.setup.vsam.name}' +
CLUSTER
//*
//*
26 changes: 13 additions & 13 deletions files/SZWESAMP/ZWEIAPF
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
//ZWEIAPF JOB
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*********************************************************************
//*
//* This JCL is used to set APF for the two datasets of Zowe
Expand All @@ -29,7 +29,7 @@
// SET PLUGLIB='{zowe.setup.dataset.authPluginLib}'
// SET PLUGLOC='SMS'
//*
//APFLOAD COMMAND 'SETPROG APF,ADD,DSN=&LOADLIB.,&LOADLOC.'
//*
//APFLOAD COMMAND 'SETPROG APF,ADD,DSN=&LOADLIB.,&LOADLOC.'
//*
//APFLIB COMMAND 'SETPROG APF,ADD,DSN=&PLUGLIB.,&PLUGLOC.'
//*
//*
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRA1
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRA2
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRA3
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
4 changes: 2 additions & 2 deletions files/SZWESAMP/ZWEIKRR1
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down Expand Up @@ -218,7 +218,7 @@ $$
PERMIT +
&USERNAME..{zowe.setup.certificate.keyring.name}.LST +
CLASS(RDATALIB) ID({zowe.setup.security.users.zowe}) +
ACCESS(CONTROL)
ACCESS(CONTROL)

/* Uncomment this command to allow other user to access key ring ... */
/* PERMIT &USERNAME..{zowe.setup.certificate.keyring.name}.LST + */
Expand Down
4 changes: 2 additions & 2 deletions files/SZWESAMP/ZWEIKRR2
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down Expand Up @@ -185,7 +185,7 @@ $$
PERMIT +
&USERNAME..{zowe.setup.certificate.keyring.name}.LST +
CLASS(RDATALIB) ID({zowe.setup.security.users.zowe}) +
ACCESS(CONTROL)
ACCESS(CONTROL)

/* Uncomment this command to allow other user to access key ring ... */
/* PERMIT &USERNAME..{zowe.setup.certificate.keyring.name}.LST + */
Expand Down
4 changes: 2 additions & 2 deletions files/SZWESAMP/ZWEIKRR3
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down Expand Up @@ -192,7 +192,7 @@ $$
PERMIT +
&USERNAME..{zowe.setup.certificate.keyring.name}.LST +
CLASS(RDATALIB) ID({zowe.setup.security.users.zowe}) +
ACCESS(CONTROL)
ACCESS(CONTROL)

/* Uncomment this command to allow other user to access key ring ... */
/* PERMIT &USERNAME..{zowe.setup.certificate.keyring.name}.LST + */
Expand Down
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRT1
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRT2
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
2 changes: 1 addition & 1 deletion files/SZWESAMP/ZWEIKRT3
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
//* signed by a recognized certificate authority (CA).
//*
//* 6) If you set zowe.verifyCertificates to
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* STRICT or NONSTRICT, then set IFROZFCA to 1
//* to connect z/OSMF certificate authority to Zowe keyring.
//*
//* 7) Customize the commands in the DD statement that matches your
Expand Down
62 changes: 31 additions & 31 deletions files/SZWESAMP/ZWEIMVS
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
//ZWEIMVS JOB
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*********************************************************************
//ZWEIMVS JOB
//*
//* This program and the accompanying materials are made available
//* under the terms of the Eclipse Public License v2.0 which
//* accompanies this distribution, and is available at
//* https://www.eclipse.org/legal/epl-v20.html
//*
//* SPDX-License-Identifier: EPL-2.0
//*
//* Copyright Contributors to the Zowe Project. 2020, 2020
//*
//*********************************************************************
//*
//* This job is used to create datasets used by a Zowe "instance"
//* Instances represent a configuration of Zowe, different from the
Expand All @@ -19,23 +19,23 @@
//* Equal to 'zowe.setup.prefix' + 'SZWELOAD',
//* Then you must also run "ZWEIMVS2".
//*
//*********************************************************************
//MKPDSE EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=A
//SYSTSIN DD *
ALLOC NEW DA('{zowe.setup.dataset.parmlib}') +
dsntype(library) dsorg(po) recfm(f b) lrecl(80) +
unit(sysallda) space(15,15) tracks
ALLOC NEW DA('{zowe.setup.dataset.authPluginLib}') +
dsntype(library) dsorg(po) recfm(u) lrecl(0) +
blksize(32760) unit(sysallda) space(30,15) tracks
//*
//MEMBCPY EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=A
//SYSUT1 DD DSN={zowe.setup.dataset.prefix}.SZWESAMP,DISP=SHR
//*********************************************************************
//MKPDSE EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=A
//SYSTSIN DD *
ALLOC NEW DA('{zowe.setup.dataset.parmlib}') +
dsntype(library) dsorg(po) recfm(f b) lrecl(80) +
unit(sysallda) space(15,15) tracks

ALLOC NEW DA('{zowe.setup.dataset.authPluginLib}') +
dsntype(library) dsorg(po) recfm(u) lrecl(0) +
blksize(32760) unit(sysallda) space(30,15) tracks
//*
//MEMBCPY EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=A
//SYSUT1 DD DSN={zowe.setup.dataset.prefix}.SZWESAMP,DISP=SHR
//SYSUT2 DD DSN={zowe.setup.dataset.parmlib},DISP=OLD
//SYSIN DD *
COPY OUTDD=SYSUT2,INDD=SYSUT1
SELECT MEMBER=((ZWESIP00,,R))
//*
//SYSIN DD *
COPY OUTDD=SYSUT2,INDD=SYSUT1
SELECT MEMBER=((ZWESIP00,,R))
//*
Loading

0 comments on commit 7679de3

Please sign in to comment.