Difference between revisions of "Create Your Own PBI Repository/10.1"

From PC-BSD Wiki
Jump to: navigation, search
(Import the Repository)
(Marked this version for translation)
 
Line 13: Line 13:
 
* create the OpenSSL signing key which will be used to sign the repository's ''INDEX''
 
* create the OpenSSL signing key which will be used to sign the repository's ''INDEX''
  
 +
<!--T:20-->
 
* create the customized modules using [[EasyPBI2/10.1|EasyPBI]]
 
* create the customized modules using [[EasyPBI2/10.1|EasyPBI]]
  
Line 43: Line 44:
 
=== Create the Customized Modules === <!--T:12-->
 
=== Create the Customized Modules === <!--T:12-->
  
 +
<!--T:21-->
 
To create the customized PBI modules, follow the instructions in [[EasyPBI2/10.1|EasyPBI]] and [[EasyPBI2/10.1#Bulk_Module_Creator|Bulk Module Creator]]. If the repository directory is ''~/myrepo/'', make sure that all of the custom modules are listed as subdirectories of that directory.
 
To create the customized PBI modules, follow the instructions in [[EasyPBI2/10.1|EasyPBI]] and [[EasyPBI2/10.1#Bulk_Module_Creator|Bulk Module Creator]]. If the repository directory is ''~/myrepo/'', make sure that all of the custom modules are listed as subdirectories of that directory.
  
 +
<!--T:22-->
 
Next, configure a FTP, HTTP, or HTTPS server to host the directory containing the custom PBI modules.  The server can be a public URL on the Internet or a private LAN server, as long as it is accessible to your target audience. Ensure that this directory is browsable by an FTP client or web browser from a client system before moving on to the next step.
 
Next, configure a FTP, HTTP, or HTTPS server to host the directory containing the custom PBI modules.  The server can be a public URL on the Internet or a private LAN server, as long as it is accessible to your target audience. Ensure that this directory is browsable by an FTP client or web browser from a client system before moving on to the next step.
  
 
=== Generate the Custom ''INDEX'' === <!--T:19-->
 
=== Generate the Custom ''INDEX'' === <!--T:19-->
  
 +
<!--T:23-->
 
To generate the signed ''INDEX'', '''cd''' to the directory containing the PBI modules and run '''pbi_makeindex''', specifying the path to the private key. In this example, the PBI modules are located in ''~/myrepo'' and the key is located in the user's home directory (''~''). Be patient as it will take a few minutes to generate the ''INDEX'' and return the command prompt.
 
To generate the signed ''INDEX'', '''cd''' to the directory containing the PBI modules and run '''pbi_makeindex''', specifying the path to the private key. In this example, the PBI modules are located in ''~/myrepo'' and the key is located in the user's home directory (''~''). Be patient as it will take a few minutes to generate the ''INDEX'' and return the command prompt.
  
  '''cd ~/myrepo'''
+
  <!--T:24-->
 +
'''cd ~/myrepo'''
 
  '''fetch <nowiki>https://github.com/pcbsd/pcbsd/raw/master/pbi-modules/PBI-categories</nowiki>'''
 
  '''fetch <nowiki>https://github.com/pcbsd/pcbsd/raw/master/pbi-modules/PBI-categories</nowiki>'''
 
  '''pbi_makeindex ../privkey.pem'''
 
  '''pbi_makeindex ../privkey.pem'''
Line 60: Line 65:
 
  Compressing PBI-INDEX...
 
  Compressing PBI-INDEX...
  
 +
<!--T:25-->
 
This will create the files ''PBI-INDEX.txz'' and ''PBI-INDEX.txz.sha1''.
 
This will create the files ''PBI-INDEX.txz'' and ''PBI-INDEX.txz.sha1''.
  
=== Import the Repository ===
+
=== Import the Repository === <!--T:26-->
  
 +
<!--T:27-->
 
To configure {{local|link=AppCafe®}} to use the custom repository, go to <span class=traverse>Configure{{rarr}}Repository Settings</span>. Click "Custom" in the screen shown in Figure 7.4a, then the "+" button. Input the URL to the repository and click "OK".
 
To configure {{local|link=AppCafe®}} to use the custom repository, go to <span class=traverse>Configure{{rarr}}Repository Settings</span>. Click "Custom" in the screen shown in Figure 7.4a, then the "+" button. Input the URL to the repository and click "OK".
  
 +
<!--T:28-->
 
[[File:customrepo1a.png|thumb|393px|'''Figure 7.4a: Add the Custom Repository to AppCafe®''']]
 
[[File:customrepo1a.png|thumb|393px|'''Figure 7.4a: Add the Custom Repository to AppCafe®''']]
  
 +
<!--T:29-->
 
It will take a few minutes for AppCafe® to read in the ''INDEX'' for the custom repository.
 
It will take a few minutes for AppCafe® to read in the ''INDEX'' for the custom repository.
  
 +
<!--T:30-->
 
<noinclude>
 
<noinclude>
 
<!-- {{refheading}} --><!-- Uncomment when citelink is used on this page -->
 
<!-- {{refheading}} --><!-- Uncomment when citelink is used on this page -->

Latest revision as of 10:36, 17 June 2014


Contents


By default, AppCafe® displays the PBIs which are available from the official PC-BSD® repository. It also supports custom repositories.

In order to create a custom repository, you need to:

  • create the OpenSSL signing key which will be used to sign the repository's INDEX
  • create the customized modules using EasyPBI
  • generate the custom INDEX and sign it with the key

This section describes these steps in more detail.

[edit] Create the Signing Key

The INDEX of a PBI repository must be digitally signed for security and identification purposes. In order to sign the INDEX, first create an OpenSSL key pair using the following commands:

openssl genrsa -out privkey.pem 4096 Generating RSA private key, 4096 bit long modulus ..................++ .............................................................................++ e is 65537 (0x10001) openssl rsa -in privkey.pem -pubout > pub.key writing RSA key

These commands will create the files privkey.pem and pub.key.

[edit] Create the Customized Modules

To create the customized PBI modules, follow the instructions in EasyPBI and Bulk Module Creator. If the repository directory is ~/myrepo/, make sure that all of the custom modules are listed as subdirectories of that directory.

Next, configure a FTP, HTTP, or HTTPS server to host the directory containing the custom PBI modules. The server can be a public URL on the Internet or a private LAN server, as long as it is accessible to your target audience. Ensure that this directory is browsable by an FTP client or web browser from a client system before moving on to the next step.

[edit] Generate the Custom INDEX

To generate the signed INDEX, cd to the directory containing the PBI modules and run pbi_makeindex, specifying the path to the private key. In this example, the PBI modules are located in ~/myrepo and the key is located in the user's home directory (~). Be patient as it will take a few minutes to generate the INDEX and return the command prompt.

cd ~/myrepo
fetch https://github.com/pcbsd/pcbsd/raw/master/pbi-modules/PBI-categories
pbi_makeindex ../privkey.pem
Building PBI-INDEX... This may take a few moments...
Fetching PBI ratings file...
/tmp/.PBI.19956/.ratings                      100% of   71 kB  134 kBps 00m00s
Adding additional package information to PBI-INDEX...
Compressing PBI-INDEX...

This will create the files PBI-INDEX.txz and PBI-INDEX.txz.sha1.

[edit] Import the Repository

To configure AppCafe® to use the custom repository, go to Configure → Repository Settings. Click "Custom" in the screen shown in Figure 7.4a, then the "+" button. Input the URL to the repository and click "OK".

Figure 7.4a: Add the Custom Repository to AppCafe®

It will take a few minutes for AppCafe® to read in the INDEX for the custom repository.

Other languages:German 12% • ‎English 100%
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox