forked from perforce/p4transfer
-
Notifications
You must be signed in to change notification settings - Fork 3
/
transfer.yaml
174 lines (148 loc) · 8.34 KB
/
transfer.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
# Save this output to a file to e.g. transfer.yaml and edit it for your configuration
# counter_name: Unique counter on target server to use for recording source changes processed. No spaces.
# Name sensibly if you have multiple instances transferring into the same target p4 repository.
# The counter value represents the last transferred change number - script will start from next change.
# If not set, or 0 then transfer will start from first change.
counter_name: p4transfer_counter
# instance_name: Name of the instance of P4Transfer - for emails etc. Spaces allowed.
instance_name: Perforce Transfer from XYZ
# For notification - if smtp not available - expects a pre-configured nms FormMail script as a URL
# E.g. expects to post using 2 fields: subject, message
# Alternatively, use the following entries (suitable adjusted) to use Mailgun for notifications
# api: "<Mailgun API key"
# url: "https://api.mailgun.net/v3/<domain or sandbox>"
# mail_from: "Fred <[email protected]>"
# mail_to:
# - "[email protected]"
mail_form_url:
# The mail_* parameters must all be valid (non-blank) to receive email updates during processing.
# mail_to: One or more valid email addresses - comma separated for multiple values
mail_to:
# mail_from: Email address of sender of emails, E.g. [email protected]
mail_from:
# mail_server: The SMTP server to connect to for email sending, E.g. smtpserver.example.com
mail_server:
# ===============================================================================
# Note that for any of the following parameters identified as (Integer) you can specify a
# valid python expression which evaluates to integer value, e.g.
# "24 * 60"
# "7 * 24 * 60"
# Such values should be quoted (in order to be treated as strings)
# -------------------------------------------------------------------------------
# sleep_on_error_interval (Integer): How long (in minutes) to sleep when error is encountered in the script
sleep_on_error_interval: 60
# poll_interval (Integer): How long (in minutes) to wait between polling source server for new changes
poll_interval: 60
# change_batch_size (Integer): changelists are processed in batches of this size
change_batch_size: 1000
# The following *_interval values result in reports, but only if mail_* values are specified
# report_interval (Integer): Interval (in minutes) between regular update emails being sent
report_interval: 30
# error_report_interval (Integer): Interval (in minutes) between error emails being sent e.g. connection error
# Usually some value less than report_interval. Useful if transfer being run with --repeat option.
error_report_interval: 15
# summary_report_interval (Integer): Interval (in minutes) between summary emails being sent e.g. changes processed
# Typically some value such as 1 week (10080 = 7 * 24 * 60). Useful if transfer being run with --repeat option.
summary_report_interval: 7 * 24 * 60
# sync_progress_size_interval (Integer): Size in bytes controlling when syncs are reported to log file.
# Useful for keeping an eye on progress for large syncs over slow network links.
sync_progress_size_interval: 500 * 1000 * 1000
# max_logfile_size (Integer): Max size of file to (in bytes) after which it should be rotated
# Typically some value such as 20MB = 20 * 1024 * 1024. Useful if transfer being run with --repeat option.
max_logfile_size: 20 * 1024 * 1024
# change_description_format: The standard format for transferred changes.
# Keywords prefixed with $. Use \\n for newlines. Keywords allowed:
# $sourceDescription, $sourceChange, $sourcePort, $sourceUser
change_description_format: $sourceDescription\n\nTransferred from p4://$sourcePort@$sourceChange
# change_map_file: Name of an (optional) CSV file listing mappings of source/target changelists.
# If this is blank (DEFAULT) then no mapping file is created.
# If non-blank, then a file with this name in the target workspace is appended to
# and will be submitted after every sequence (batch_size) of changes is made.
# Default type of this file is text+CS32 to avoid storing too many revisions.
# File must be mapped into target client workspace.
# File can contain a sub-directory, e.g. change_map/change_map.csv
# Note that due to the way client workspace views are created the local filename
# should include a valid source path including depot name, e.g.
# //depot/export/... -> depot/export/change_map.csv
change_map_file:
# superuser: Set to n if not a superuser (so can't update change times - can just transfer them).
superuser: y
# ignore_files: An array of regex patterns which are used to ingore any matching files.
# Allows you to ignore some issues which cause transfer problems.
# E.g.
# ignore_files:
# - "some/files/to/*ignore$"
ignore_files:
source:
# P4PORT to connect to, e.g. some-server:1666 - if this is on localhost and you just
# want to specify port number, then use quotes: "1666"
p4port:
# P4USER to use
p4user:
# P4CLIENT to use, e.g. p4-transfer-client
p4client:
# P4PASSWD for the user - valid password. If blank then no login performed.
# Recommended to make sure user is in a group with a long password timeout!.
# Make sure your P4TICKETS file is correctly found in the environment
p4passwd:
# P4CHARSET to use, e.g. none, utf8, etc - leave blank for non-unicode p4d instance
p4charset:
target:
# P4PORT to connect to, e.g. some-server:1666 - if this is on localhost and you just
# want to specify port number, then use quotes: "1666"
p4port:
# P4USER to use
p4user:
# P4CLIENT to use, e.g. p4-transfer-client
p4client:
# P4PASSWD for the user - valid password. If blank then no login performed.
# Recommended to make sure user is in a group with a long password timeout!
# Make sure your P4TICKETS file is correctly found in the environment
p4passwd:
# P4CHARSET to use, e.g. none, utf8, etc - leave blank for non-unicode p4d instance
p4charset:
# workspace_root: Root directory to use for both client workspaces.
# This will be used to update the client workspace Root: field for both source/target workspaces
# They must be the same.
# Make sure there is enough space to hold the largest single changelist that will be transferred!
workspace_root: /work/transfer
# views: An array of source/target view mappings
# You are not allowed to specify both 'views' and 'stream_views' - leave one or other blank!!
# Each value is a string - normally quote. Standard p4 wildcards are valid.
# These values are used to construct the appropriate View: fields for source/target client workspaces
# It is allowed to have exclusion mappings - by specifying the '-' as first character in 'src'
# entry - see last example below.
views:
- src: //depot/source_path1/...
targ: //import/target_path1/...
- src: //depot/source_path2/...
targ: //import/target_path2/...
- src: -//depot/source_path2/exclude/*.tgz
targ: //import/target_path2/exclude/*.tgz
# transfer_target_stream: The name of a special target stream to use - IT SHOULD NOT CONTAIN FILES!!
# This will be setup as a mainline stream, with no sharing and with import+ mappings
# It is in standard stream name format, e.g. //<depot>/<name> or //<depot>/<mid>/<name>
# e.g. transfer_target_stream: //targ_streams/transfer_target
transfer_target_stream:
# stream_views: An array of source/target stream view mappings and other record fields.
# You are not allowed to specify both 'views' and 'stream_views' - leave one or other blank
# Each src/targ value is a string with '*' p4 wildcards to match stream names (like 'p4 streams //depot/rel*')
# Multiple wildcards are allowed, but make sure the number of wildcards matches between source and target.
# Please note that target depots must exist.
# Target streams will be created as required using the specified type/parent fields.
# Field 'type:' has allowed values: mainline, development, release
# Field 'parent:' should specify a suitable parent if you are creating development or release streams.
stream_views:
- src: //streams_src/main
targ: //streams_targ/main
type: mainline
parent: ''
- src: //streams_src2/release*
targ: //streams_targ2/rel*
type: mainline
parent: //streams_targ2/main
- src: //src3_streams/*rel*
targ: //targ3_streams/*release*
type: mainline
parent: //targ3_streams/main