Working with packages
A package contains URIs, properties, and configuration data that help define how the application is constructed and deployed. To deploy a package, you create an instance that represents a version of this content, with its referenced URI content retrieved and stored in the database. For more information about packages, see Packages.
You can perform the following actions with packages:
- To create a package
- To add references to a package
- To add remote references to a package
- To add a dependency between two references in a package
- To add a dependency between two pieces of content in a repository
- To add pathname filters to a reference
- To add an analyzer to an existing package
- To add properties to a package
- To set the format for package instance naming
- To set the next increment version number for the auto-incrementing value
- To modify configuration data for a reference
- To enable role-based access permissions for a package
To create a package
- On the Define tab, from the left menu, click Packages.
- Click New Package.
- Enter an appropriate name for the new package.
- From the Instance Lock Default list, select an instance lock value (Locked or Unlocked).
By default, the instance is unlocked. If the instance is locked, you cannot edit its references, properties, and existing configurations. - Click the Roles field and from the Manage Roles dialog box, select the roles allowed to access the package. If you select a specific role, then only users with this specific role are allowed to see the package.
The default role for accessing the package is Unassigned. - Click Create.
The new package summary appears with sections for adding references and analyzers, package properties, and configuration data. You have the following options:- Continue to configure the package by making the needed changes, such as adding references or properties as described in the following sections.
- Click Deploy to create a deployable version of the package.
- Click New Instance to create an instance of the package.
To add references to a package
- On the Define tab, from the left menu, click Packages.
- Click the name of the package to which you want to add a reference.
- On the References tab, click Add Reference.
- Enter an appropriate name for the reference.
Select the method for retrieving the content.
(Optional) Make other selections as required. Fields depend on the method that you selected in the preceding step.
If you want content from your references not to be pulled into your local database during instance creation, add remote references to the package. See Remote-reference. Otherwise, specify the server and the location of the file on that server in the appropriate fields, and keep the default false value in the Remote reference field.- Click Create.
- Continue to define the reference by adding filters or analyzers.
- Click Configuration to specify configuration or template details.
On the Configuration window, you can click Definition to return to this package definition.
To add remote references to a package
- On the Define tab, from the left menu, click Packages.
- Click the name of the package to which you want to add a reference.
- On the References tab, click Add Reference.
- Enter an appropriate name for the reference.
Select the method for retrieving the content.
- Select true from the Remote reference field. For more information, see Remote-reference.
In the Location field, specify the location of the content on a remote server. Provide the path to the remote server in the following format:
file:///<server>/<path>The Server field is dimmed, since you already specified it in the Location field.
Click Create.
To add a dependency between two references in a package
- On the Define tab, from the left menu, click Packages.
- Click the name of the package to which you want to add a dependency.
- Locate the reference that depends on other references being deployed before it, and click the Add New Dependency link.
- From the selection list, select the reference that must be deployed prior to this reference.
- Click Add.
BMC Release Package and Deployment (RPD) checks that no circular dependencies occur. - Continue to add dependencies for the reference as needed.
- When done, you can click one of the buttons Deploy or New Instance.
To add a dependency between two pieces of content in a repository
- On the Define tab, from the left menu, click Repositories.
- Click the name of the repository to which you want to add a dependency.
- Locate the content that depends on other content being deployed before it, and click the corresponding link in the Dependencies column (it says None if the content has no existing dependencies; otherwise, it lists the dependencies).
- Select the content that must be deployed before this content.
- Click Submit.
RPD checks that no circular dependencies occur. - Continue to add dependencies for the content as needed.
To add pathname filters to a reference
- On the Define tab, from the left menu, click Packages.
- Click the name of the package and then click the reference to which you want to add the pathname filter.
- In the Pathname Filters tab, click Add Filter.
- From the Flag list, select the appropriate flag:
- Accept: Retrieves files of specified pattern for deployment.
- Reject: Skips files of specified pattern for deployment.
- Add the appropriate Pattern of the file path that has to be accepted or rejected.
For example, specify %txt% to retrieve only text files from the specified location. - Click and drag
to move pathname filters to the order that you want.
- Click
to save the pathname filter.
You can specify multiple pathname filters for the package as per your requirement.
To add an analyzer to an existing package
- On the Define tab, from the left menu, click Packages.
- Click the name of the package to which you want to add an analyzer.
- In the References section, click the name of a reference that is associated with an existing URI.
- In the Analyzers section, click Add Analyzer.
- From the Type list box, select an appropriate analyzer, and click Submit.
RPD creates a new analyzer and associates it with the resource reference.
To add properties to a package
- On the Define tab, from the left menu, click Packages.
- Click the name of the package to which you want to add a property.
- On the Properties tab, click Add Property.
- Enter a name for the new property.
- Enter a value for the new property.
- To encrypt the property, click the Encrypt Value icon.
- Click the Submit checkmark icon.
To set the format for package instance naming
You can specify the versioning pattern when creating a package.
- On the Define tab, from the left menu, click Packages.
- Click the name of the package.
- Edit the value in the Instance Name Format field.
(click the image to expand it) - Click the Submit icon.
The following table describes the interpreted values that you can use for the instance name format.
Format | Description | Example |
---|---|---|
[#] | The next incremental value | 123 |
%a | An abbreviated textual representation of the day | Sun |
%A | A full textual representation of the day | Sunday |
%d | Two-digit day of the month (with leading zeros) | 08 |
%e | Day of the month, with a space preceding single digits. Not implemented as described on Windows. See below for more information. | 8 |
%j | Day of the year, three digits with leading zeros | 001 to 366 |
%u | ISO-8601 numeric representation of the day of the week | 1 (Monday), 7 (Sunday) |
%w | Numeric representation of the day of the week | 0 (Sunday), 6 (Saturday) |
%U | Week number of the given year, starting with the first Sunday as the first week | 13 (for the 13th full week of the year) |
%V | ISO-8601:1988 week number of the given year, starting with the first week of the year with at least four week days, with Monday being the start of the week | 01 through 53 (where 53 accounts for an overlapping week) |
%W | A numeric representation of the week of the year, starting with the first Monday as the first week | 46 (for the 46th week of the year beginning with a Monday) |
%b | Abbreviated month name, based on the locale | Jan |
%B | Full month name, based on the locale | January |
%m | Two-digit representation of the month | 01 (January), 12 (December) |
%C | Two-digit representation of the century (year divided by 100, truncated to an integer) | 19 for the 20th Century |
%g | Two-digit representation of the year going by ISO-8601:1988 standards (see %V) | 09 for the week of January 6, 2009 |
%G | The full four-digit version of %g | 2008 for the week of January 3, 2009 |
%y | Two-digit representation of the year | 09 for 2009, 79 for 1979 |
%Y | Four-digit representation for the year | 2038 |
%H | Two-digit representation of the hour in 24-hour format | 00, 23 |
%I | Two-digit representation of the hour in 12-hour format | 01, 12 |
%l (lowercase 'L') | Hour in 12-hour format, with a space preceding single digits | 1, 12 |
%M | Two-digit representation of the minute | 00 through 59 |
%p | Uppercase AM or PM based on the given time | AM for 00:31, PM for 22:23 |
%P | Lowercase am or pm based on the given time | am for 00:31, pm for 22:23 |
%r | Same as "%I:%M:%S %p" | 09:34:17 PM |
%R | Same as "%H:%M" | 00:35 |
%S | Two-digit representation of the second | 00, 59 |
%T | Same as "%H:%M:%S" | 21:34:17 |
%X | Preferred time representation based on locale, without the date | 03:59:16 |
%z | Either the time zone offset from UTC or the abbreviation (depends on operating system) | -0500 or EST for Eastern Time |
%Z | The time zone offset/abbreviation option NOT given by %z (depends on operating system) | -0500 or EST for Eastern Time |
%c | Preferred date and time stamp based on local | Tue Feb 5 00:45:10 2009 |
%D | Same as "%m/%d/%y" | 02/05/09 |
%F | Same as "%Y-%m-%d" (commonly used in database date stamps) | 2009-02-05 |
%s | UNIX Epoch Time time stamp (same as the time() function) | 305815200 for September 10, 1979 08:40:00 AM |
%x | Preferred date representation based on locale, without the time | 02/05/09 |
%% | A literal percentage character ("%") | --- |
To set the next increment version number for the auto-incrementing value
- On the Define tab, from the left menu, click Packages.
- Click the name of the package.
- Enter the value in the Next Instance Number field.
- Click the Submit icon.
To modify configuration data for a reference
- On the Define tab, from the left menu, click Packages.
- Click the name of the package.
- In the References tab, click the reference that you want to edit.
- Click Configuration.
- In the Configuration tab, click Edit.
- Edit the configuration data.
- Click Save.
To enable role-based access permissions for a package
- On the Define tab, from the left menu, click Packages.
- On the List tab, find the necessary package and click it to view the details.
- In the Roles field, click the link.
- In the Manage Roles dialog box, add the access permissions for the necessary roles using the following actions:
- To add access permission for one or more roles, select the necessary roles on the left, and click Add Item(s)
- To add access permission for all roles, click Add All Items
- To disable permissions for some roles, select them on the right and click Remove Item(s)
- To disable permissions for all roles, click Remove All Items
- Click Save.