# If the server.id matches the name below, this instance runs as a relica. export P4REPLICANAME=REPL_REPNAME # P4MASTERNAME is server.id of Master for this instance export P4MASTERNAME=MASTER_NAME # This is the DNS name of the master server: export P4MASTER=REPL_DNSNAME # The setting below should be ssl: if this instance uses ssl. export SSL_PREFIX=REPL_SSLPREFIX export P4MASTERPORTNUM=REPL_P4PORT export P4PORT=${SSL_PREFIX}${P4MASTERPORTNUM} export P4BROKERPORTNUM=REPL_P4BROKERPORT export P4BROKERPORT=${SSL_PREFIX}${P4BROKERPORTNUM} export P4D_FLAGS="-p $P4PORT -r $P4ROOT -J $P4JOURNAL -L $P4LOG -q -d" export PROXY_TARGET=${SSL_PREFIX}${P4MASTER}:${P4MASTERPORTNUM} export PROXY_PORT=$P4PORT if [[ "$SERVERID" == "$P4MASTERNAME" ]]; then export P4REPLICA=FALSE else export P4REPLICA=TRUE fi # P4Web settings: export P4WEBBIN=${P4HOME}/bin/p4web_${SDP_INSTANCE} export P4WEBLOG=${P4HOME}/logs/p4web.log export P4WEBPORT=REPL_P4WEBPORT # Authenticated Browse only mode: export P4WEBARGS="-B -p $P4PORT -w $P4WEBPORT -U $OSUSER -L $P4WEBLOG" # P4FTP settings: export P4FTPPORT=REPL_P4FTPPORT export P4FTPBIN=${P4HOME}/bin/p4ftpd_${SDP_INSTANCE} export P4FTPLOG=${P4HOME}/logs/ftp.log export P4FTPARGS="-d -l $P4FTPPORT -p $P4PORT -u $OSUSER -L $P4FTPLOG"
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 15465 | alan_petersen | Merging using sdp_alan_petersen | ||
//guest/perforce_software/sdp/dev/Server/Unix/p4/common/config/instance_vars.template | |||||
#7 | 14136 | C. Thomas Tyler |
Routine merge down to dev from main for SDP using perforce_software-sdp-dev. |
||
#6 | 13906 | C. Thomas Tyler |
Normalized P4INSTANCE to SDP_INSTANCE to get Unix/Windows implementations in sync. Reasons: 1. Things that interact with SDP in both Unix and Windows environments shoudn't have to account for this obscure SDP difference between Unix and Windows. (I came across this doing CBD work). 2. The Windows and Unix scripts have different variable names for defining the same concept, the SDP instance. Unix uses P4INSTANCE, while Windows uses SDP_INSTANCE. 3. This instance tag, a data set identifier, is an SDP concept. I prefer the SDP_INSTANCE name over P4INSTANCE, so I prpose to normalize to SDP_INSTANCE. 4. The P4INSTANCE name makes it look like a setting that might be recognized by the p4d itself, which it is not. (There are other such things such as P4SERVER that could perhaps be renamed as a separate task; but I'm not sure we want to totally disallow the P4 prefix for variable names. It looks too right to be wrong in same cases, like P4BIN and P4DBIN. That's a discussion for another day, outside the scope of this task). Meanwhile: * Fixed a bug in the Windows 2013.3 upgrade script that was referencing undefined P4INSTANCE, as the Windows environment defined only SDP_INSTANCE. * Had P4INSTANCE been removed completely, this change would likely cause trouble for users doing updates for existing SDP installations. So, though it involves slight technical debt, I opted to keep a redundant definition of P4INSTANCE in p4_vars.template, with comments indicating SDP_INSTANCE should be used in favor of P4INSTANCE, with a warning that P4INSTANCE may go away in a future release. This should avoid unnecessary upgrade pain. * In mkdirs.sh, the varialbe name was INSTANCE rather than SDP_INSTANCE. I changed that as well. That required manual change rather than sub/replace to avoid corrupting other similar varialbe names (e.g. MASTERINSTANCE). This is a trivial change technically (a substitute/replace, plus tweaks in p4_vars.template), but impacts many files. |
||
#5 | 12923 | C. Thomas Tyler |
Routine merge down from main to dev. Resolved with 'p4 resolve -as', no merges or conflicts. |
||
#4 | 12028 | C. Thomas Tyler | Refreshed SDP dev branch, merging down from main. | ||
#3 | 11523 | Russell C. Jackson (Rusty) |
Modified P4BROKERPORTNUM to just be the port number and added P4BROKERPORT to instance_vars to be consistent with P4PORT. Also makes it easier to modify p4review.py to use P4BROKERPORT rather than P4PORT for the subject line when needed. |
||
#2 | 11490 | Russell C. Jackson (Rusty) |
Added SSL_PREFIX back and P4MASTERPORTNUM in order to support the sync_replica.sh and weekly_sync_replica.sh scripts. |
||
#1 | 11477 | Russell C. Jackson (Rusty) |
Updated to use /usr/bin/env python Added workshop header. Changed cfg to config. |
||
//guest/perforce_software/sdp/dev/Server/Unix/p4/common/cfg/instance_vars.template | |||||
#1 | 11466 | Russell C. Jackson (Rusty) |
Initial work to simplify p4_vars and remove cluster stuff. Testing of named instances surfaced some bugs that are in prod sdp, now fixed in dev. Added three triggers from RCJ SDP Moved p4review.cfg into the new /p4/common/cfg to go along with the instance_vars files. mkdirs.sh now generates an instance_p4review.cfg as well. Removed incremental p4verify to clean up a bit. It didn't support replicas and was really never used. All port settings now live in <instance>_vars file. You set what you want the ports to be in mkdirs.sh. There is no more fancy logic to try to guess what the port should be. You set it, and that is what it is. Remaining to do is to updated scripts to not need p4master_run. Saved that work for later since this is tested and works. |