Changeset 2290 in ProjectBuilder for devel


Ignore:
Timestamp:
Sep 4, 2017, 1:21:20 PM (7 years ago)
Author:
Bruno Cornec
Message:

Document pb Env var, URLs and DIRs !!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • devel/pb-modules/etc/pb.yml.pod

    r2286 r2290  
    664664 Nature: Optional
    665665 Key: project (as defined in the -p option or PBPROJ environment variable)
    666  Value: whatever. As soon as this is defined, then that project is known as not well formed (have a subdirectory in its tar file under which all sources are put named project-version). This should be reported upstream to the project. tar files generated by project-builder to not suffer from that. This is valid when packaging for tar files and not CMS.
     666 Value: whatever. As soon as this is defined, then that project is known as not well formed (have a subdirectory in its tar file under which all sources are put named project-version). This should be reported upstream to the project. tar files generated by project-builder.org to not suffer from that. This is valid when packaging for tar files and not CMS.
    667667 Conffile: project
    668668 Example: pbwf afio = 1
     
    11101110=over 4
    11111111
    1112 =item B<pb_URL>
    1113 
    1114 =item B<pb_directory_desc>
    1115 
    1116 =item B<pb_environment_variables>
     1112=item B<pb URLs>
     1113
     1114 The pbprojurl and pbconfurl parameters support multiple schemas to point to the repositories to use.
     1115 They are parsed by project-builder.org to communicate with them.
     1116
     1117 The protocols can be git, git+svn, svk, svn, cvs, hg.
     1118 If you have write access to the repository, you'll generally use an ssh access which will be noted by a +ssh at the end of the protocol used. If you don't you may use a +http(s) e.g. to access the repository.
     1119
     1120 Examples:
     1121
     1122 pbprojurl:
     1123   fossology: git+https://github.com/fossology/fossology.git
     1124   linuxcoe: cvs+ssh://:ext:bcornec@linuxcoe.cvs.sourceforge.net:/cvsroot/linuxcoe
     1125   pb: svn+ssh://svn.mondorescue.org/prj/svn/pb
     1126
     1127 => You access the upstream FOSSology project in read mode (by https) and the project uses git as a VCS, that will also be used by project-builder.org to build.
     1128 => You access the upstream LinuxCOE project in write mode (by ssh) and the project uses CVS as a VCS, that will also be used by project-builder.org to build.
     1129 => For Project-builder.org itself, you access the upstream LinuxCOE project in write mode (by ssh) and the project uses CVS as a VCS, that will also be used by project-builder.org to build.
     1130 => You access the upstream project-builder.org project in write mode (by ssh) and the project uses subversion as a VCS, that will also be used by project-builder.org to build.
     1131
     1132 If you use instead:
     1133   pb: git+svn+ssh://svn.mondorescue.org/prj/svn/pb
     1134
     1135 => You access the upstream project-builder.org project in write mode (by ssh) and the project uses subversion as a VCS, and you use git svn to manage locally the software with git, that will also be used by project-builder.org to build.
     1136
     1137
     1138 In some cases, there is no repository and the files are hosted remotely, in which case you can use an http(s) or ftp protocol
     1139
     1140 Examples:
     1141
     1142 pbprojurl:
     1143   afio: ftp://localhost/src/afio-2.5.tar.gz
     1144
     1145 => You access the project in read mode as a tar compressed file format using ftp to have access to it and that will also be used by project-builder.org to build.
     1146
     1147
     1148=item B<pb Directories>
     1149
     1150 In order to use project-builder.org to build packages for a project, you need to declare certain directories in your configurationfile, and two URLS, as defined in the previous paragraph, linked to them.
     1151
     1152 The first couple to declare is the pbconfurl and pbconfdir. They declare the location of the repository containing project-builder.org configuration files and the local directory in which they are checked out. They do not need to be hosted in the upstream repository and can be managed completely separately. If pbconfdir is not defined, by default it will be taken as the concatention of pbdefdir and the project name. If that's not the case in your setup, then specify the pbconfdir value
     1153
     1154 Examples:
     1155
     1156 pbconfurl:
     1157  python-redfish: git+ssh://git@github.com:bcornec/python-redfish.git
     1158  fossology: git+https://github.com/fossology/fossology.git
     1159  uuwl: git+svn+ssh://svn.mondorescue.org/prj/svn/pb/projects/uuwl/pbconf
     1160  pb: git+svn+ssh://svn.mondorescue.org/prj/svn/pb/pbconf
     1161  afio: git+svn+ssh://svn.project-builder.org/prj/svn/pb/projects/afio/pbconf
     1162  linuxcoe: cvs+ssh://:ext:bcornec@linuxcoe.cvs.sourceforge.net:/cvsroot/linuxcoe/pbconf
     1163
     1164 pbconfdir:
     1165  python-redfish: $ENV{'HOME'}/Work/bruno/prj/python-redfish/pbconf
     1166  fossology: $ENV{'HOME'}/Work/bruno/prj/fossology/git/pbconf
     1167  uuwl: $ENV{'HOME'}/svn-git/pb/projects/uuwl/pbconf
     1168
     1169 pbdefdir:
     1170  default: $ENV{'HOME'}/svn-git/pb/projects
     1171  python-redfish: $ENV{'HOME'}/Work/bruno/prj
     1172  fossology: $ENV{'HOME'}/Work/bruno/prj/fossology
     1173  uuwl: $ENV{'HOME'}/svn-git
     1174  pb: $ENV{'HOME'}/svn-git
     1175
     1176 => You access the project-builder.org configuration files for python-redfish in write mode (by ssh) and this project is using git as a VCS, that will also be used by project-builder.org to build packages. The first time, project-builder.org will clone the git repository from the pbconfurl URL into the pbconfdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch. The pbdefdir will be used for other parameters, but the pbconfdir value takes precedence (in this case both variable mean the same local location anyway). Here the upstream python-redfish project is hosting the pbconf info directly.
     1177 => You access the project-builder.org configuration files for FOSSology in read-only mode (by https) and this project is using git as a VCS, that will also be used by project-builder.org to build packages. The first time, project-builder.org will clone the git repository from the pbconfurl URL into the pbconfdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch. The pbdefdir will be used for other parameters, but the pbconfdir value takes precedence (in this case both variable mean the same local location anyway). Here the upstream python-redfish project is hosting the pbconf info directly.
     1178 => You access the project-builder.org configuration files for UUWL in write mode (by ssh) and this project is using SVN as a VCS to manage the repo and git svn will be used by project-builder.org to build packages. The first time, project-builder.org will clone the SVN repository from the pbconfurl URL into the pbconfdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch. The pbdefdir will be used for other parameters, but the pbconfdir value takes precedence (in this case variables point to different locations). Here the upstream UUWL project is not hosting the pbconf info directly, which is managed in the upstream SVN project-builder.org repository.
     1179 => You access the project-builder.org configuration files for project-builder.org in write mode (by ssh) and this project is using SVN as a VCS to manage the repo and git svn will be used by project-builder.org to build packages. The first time, project-builder.org will clone the SVN repository from the pbconfurl URL into a directory whose name is the concatenation of the pb pbdefdir path and then the project name (PBPROJ value setup with the -p option see below, here pb), expanding the HOME directory on the fly, as there is no pbconfdir value setup for this project. If the project is already cloned there it will just use it, with the current branch. Here the upstream project-builder.org project is hosting the pbconf info directly.
     1180 => You access the project-builder.org configuration files for afio in write mode (by ssh) and this project is using SVN as a VCS to manage the repo and git svn will be used by project-builder.org to build packages. The first time, project-builder.org will clone the SVN repository from the pbconfurl URL into a directory whose name is the concatenation of the default pbdefdir path and then the project name (PBPROJ value setup with the -p option see below, here afio), expanding the HOME directory on the fly, as there is no pbconfdir value setup for this project, and no value for this project for the pbdefdir parameter, only the default one. If the project is already cloned there it will just use it, with the current branch. Here the upstream afio project is not hosting the pbconf info directly, which is managed in the upstream SVN project-builder.org repository.
     1181 => You access the project-builder.org configuration files for LinuxCOE in write mode (by ssh) and this project is using CVS as a VCS, that will be used by project-builder.org to build packages. The first time, project-builder.org will clone the CVS repository from the pbconfurl URL into a directory whose name is the concatenation of the default pbdefdir path and then the project name (PBPROJ value setup with the -p option see below, here linuxcoe), expanding the HOME directory on the fly, as there is no pbconfdir value setup for this project, and no value for this project for the pbdefdir parameter, only the default one. If the project is already cloned there it will just use it, with the current branch. Here the upstream LinuxCOE project is hosting the pbconf info directly.
     1182
     1183 Note that ultimately, if pbdefdir is not defined, project-builder.org will use /var/cache by default, which may fail if you do not have appropriate write rights.
     1184
     1185 The second couple to declare is the pbprojurl and pbprojdir. Similarly, they declare the location of the repository containing the upstream project files and the local directory in which they are checked out. If pbprojdir is not defined, by default it will be taken as the concatention of pbdefdir and the project name. If that's not the case in your setup, then specify the pbprojdir value
     1186
     1187 Examples:
     1188
     1189 pbprojurl:
     1190  python-redfish: git+ssh://git@github.com:bcornec/python-redfish.git
     1191  fossology: git+ssh://git@github.com:fossology/fossology.git
     1192  uuwl: git+svn+ssh://svn.mondorescue.org/prj/svn/uuwl
     1193  pb: git+svn+ssh://svn.mondorescue.org/prj/svn/pb
     1194  afio: ftp://localhost/src/afio-2.5.tar.gz
     1195  linuxcoe: cvs+ssh://:ext:bcornec@linuxcoe.cvs.sourceforge.net:/cvsroot/linuxcoe
     1196
     1197 pbprojdir:
     1198  fossology: $ENV{'HOME'}/Work/bruno/prj/fossology/git
     1199  pb: $ENV{'HOME'}/svn-git/pb
     1200  linuxcoe: $ENV{'HOME'}/LinuxCOE/cvs
     1201
     1202 pbdefdir:
     1203  default: $ENV{'HOME'}/svn-git/pb/projects
     1204  python-redfish: $ENV{'HOME'}/Work/bruno/prj
     1205  fossology: $ENV{'HOME'}/Work/bruno/prj/fossology
     1206  uuwl: $ENV{'HOME'}/svn-git
     1207  pb: $ENV{'HOME'}/svn-git
     1208
     1209 => You access the upstream files for python-redfish in write mode (by ssh) and this project is using git as a VCS, that will also be used by project-builder.org to manage the sources. The first time, project-builder.org will clone the git repository from the pbprojurl URL into a directory whose name is the concatenation of the python-redfish pbdefdir path and then the project name (PBPROJ value setup with the -p option see below, here python-redfish), expanding the HOME directory on the fly, as there is no pbprojdir value setup for this project. If the project is already cloned there it will just use it, with the current branch.
     1210 => You access the upstream files for FOSSology in write mode (by ssh) and this project is using git as a VCS, that will also be used by project-builder.org to manage the sources. The first time, project-builder.org will clone the git repository from the pbprojurl URL into the pbprojdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch. The pbdefdir will be used for other parameters, but the pbprojdir value takes precedence (in this case variables point to different locations).
     1211 => You access the upstream files for UUWL in write mode (by ssh) and this project is using SVN as a VCS to manage the repo and git svn will be used by project-builder.org to manage the sources. The first time, project-builder.org will clone the git repository from the pbprojurl URL into a directory whose name is the concatenation of the uuwl pbdefdir path and then the project name (PBPROJ value setup with the -p option see below, here uuwl), expanding the HOME directory on the fly, as there is no pbprojdir value setup for this project. If the project is already cloned there it will just use it, with the current branch.
     1212 => You access the upstream files for project-builder.org in write mode (by ssh) and this project is using SVN as a VCS to manage the repo and git svn will be used by project-builder.org to manage the sources. The first time, project-builder.org will clone the git repository from the pbprojurl URL into the pbprojdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch.
     1213 => You access the upstream files for afio in read-only mode and this project, which isn't developed anymore upstream, is just providing a compressed tar file using FTP as a VCS and it will be used by project-builder.org to manage the sources. The first time, project-builder.org will extract the sources from the tar file pointed to by the pbprojurl URL into a directory whose name is the concatenation of the default pbdefdir path, as there is no afio entry for this parameter, and then the project name (PBPROJ value setup with the -p option see below, here afio), expanding the HOME directory on the fly, as there is no pbprojdir value setup for this project.
     1214 => You access the upstream files for LinuxCOE in write mode (by ssh) and this project is using CVS as a VCS to manage the repo and it will be used by project-builder.org to manage the sources. The first time, project-builder.org will export the CVS repository from the pbprojurl URL into the pbprojdir directory, expanding the HOME directory on the fly. If the project is already cloned there it will just use it, with the current branch.
     1215
     1216
     1217 In order to help you validate the value for a given parameter, you may want to use pb -p pbproj getconf param_to_consider
     1218
     1219=item B<pb Environment Variables>
     1220
     1221 The following environment variables are used by pb when declared to change its behaviour:
     1222
     1223 PBACCOUNT
     1224   Default: Empty
     1225   Value: Login to use to connect to the VM/VE/RM. Also see -a option.
     1226
     1227 PBPROJ
     1228   Default: Empty
     1229   Value: Name of the project to build for. Also see -p option.
     1230
     1231 PBROOTDIR
     1232   Default: Empty
     1233   Value: Root directory of the configuration files for this project. Also see -r option.
     1234
     1235 PBV
     1236   Default: Empty
     1237   Value: List of VM/VE/RM to build for, separated by ','. Also see -m option
     1238
     1239 PBVCSOPT
     1240   Default: Empty
     1241   Value: Options to pass to the VCS command when interacting with the repository.
     1242
     1243 PBVMOPT
     1244   Default: Empty
     1245   Value: Options to pass to the VM engine to launch VMs.
     1246
     1247 PBVMTMOUT
     1248   Default: 120
     1249   Value: Timeout in seconds to wait for th launch of the VM before communicating with it. Also see parameter vmtmout in configuration files. Takes precedence.
     1250
     1251 TMPDIR
     1252   Default: /tmp
     1253   Value: Directory where temporary files will be created.
     1254
     1255 ftp_proxy
     1256 http_proxy
     1257 https_proxy
     1258   Default: Empty
     1259   Value: URL of the proxy server to use for these protocols.
     1260
     1261
     1262 The following environment variables are generated by pb and can be used in build scripts:
     1263
     1264 PBBUILDDIR
     1265   Value: Build directory (pbbuild) where packages are created locally. See the schema of ProjectBuilder::Env man page.
     1266
     1267 PBCMSLOGFILE
     1268   Value: Intermediate log file generated for stable versions to create ChangeLog.
     1269
     1270 PBCONFDIR
     1271   Value: Configuration directory (pbconf) where configuration files for the project are stored. See the schema of ProjectBuilder::Env man page. See pbconfdir parameter.
     1272
     1273 PBDEFDIR
     1274   Value: Default directory where the project-builder.org will host host files for the projects, parent of PBPROJ directories. See the schema of ProjectBuilder::Env man page. See pbdefdir parameter.
     1275
     1276 PBDESTDIR
     1277   Value: Destination directory (pbdelivery) where intermediate tar files are created locally. See the schema of ProjectBuilder::Env man page.
     1278
     1279 PBDIR
     1280   Value: Directory where an upstream version is located. See the schema of ProjectBuilder::Env man page. Correspond to PBROOTDIR for project-builder.org conf files.
     1281
     1282 PBETC
     1283   Value: .pbrc.yml configuration file of the user located in his HOME directory.
     1284
     1285 PBPACKAGER
     1286   Value: E-mail address of the packager, used also to get GPG information. See pbpackager parameter.
     1287
     1288 PBPASSFILE
     1289   Value: File containing the pass phrase for the GPG signature. Used with PBPASSPATH. See pbpassfile parameter.
     1290
     1291 PBPASSPATH
     1292   Value: Path of the file containing the pass phrase for the GPG signature. Used with PBPASSFILE. See pbpasspath parameter.
     1293
     1294 PBPASSPHRASE
     1295   Value: Pass phrase for the GPG signature. Used instead of PBPASSPATH+PBPASSFILE. See pbpassphrase parameter.
     1296
     1297 PBPKG
     1298   Value: Name of the package built.
     1299
     1300 PBPROJDIR
     1301   Value: Directory where an upstream project is located. See the schema of ProjectBuilder::Env man page. Correspond to PBPROJ dir under PBDEFDIR for project-builder.org conf files.
     1302
     1303 PBPROJTAG
     1304   Value: Tag of the packages created, indicating the build procedure version. See pbprojtag parameter.
     1305
     1306 PBPROJVER
     1307   Value: Version of the packages created. See pbprojver parameter.
     1308
     1309 PBREVISION
     1310   Value: Revision of the project in the VCS. Revision for SVN, commit ID for git, ...
     1311
     1312 PBVMPORT
     1313   Value: Offset to the base port to communicate with the VM
     1314
     1315 PBSOLDESTDIR
     1316   Value: Target directory for the Solaris prototype
    11171317
    11181318=back
     
    11201320=head1 COPYRIGHT
    11211321
    1122  (c) B. Cornec 2007-2016
     1322 (c) B. Cornec 2007-today
    11231323 Eric Anderson's changes are (c) Copyright 2012 Hewlett Packard
    11241324 Provided under the Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0) Creative Common License
Note: See TracChangeset for help on using the changeset viewer.