|
@@ -0,0 +1,213 @@
|
|
|
|
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
|
|
+ <html lang="en" xmlns="http://www.w3.org/1999/xhtml">
|
|
|
|
+ <head>
|
|
|
|
+ <title>Installing Passbolt on Linux (Debian 10)</title>
|
|
|
|
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
|
|
+ <script type="text/javascript" src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
|
|
|
|
+ <script type="text/javascript">
|
|
|
|
+ $(function(){
|
|
|
|
+ $('textarea').each(function(i,e){
|
|
|
|
+ theTextarea = $(this);
|
|
|
|
+ theTextarea.height((theTextarea[0].scrollHeight-5) +'px');
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ $('li').each(function(i,e){
|
|
|
|
+ var uuid = 'li_' + Math.floor(Math.random() * Math.floor(1000000)).toString() + '_' + i.toString();
|
|
|
|
+ $(this).contents().wrap('<span id="'+ uuid +'"><label for="cb_'+ uuid +'"></label></span>');
|
|
|
|
+ $(this).prepend('<input type="checkbox" class="completeBox" id="cb_' + uuid +'" rel="'+ uuid +'" />')
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ $('code,div.codeBlock,textarea.codeBlock').each(function(i,e){
|
|
|
|
+ theElement = $(this);
|
|
|
|
+ var lines = theElement.html().split("\n");
|
|
|
|
+ theElement.empty();
|
|
|
|
+ for(l=0;l<lines.length;l++){
|
|
|
|
+ if($.trim(lines[l]) != '' && $.trim(lines[l]).substr(0,1) != '#' && $.trim(lines[l]).indexOf(' #') == -1 && lines[l].substr(0, 4).toUpperCase() != 'REM '){
|
|
|
|
+ theElement.append('<input type="image" src="images/clipboard.png" value="" class="copy-text" rel="copy_'+ i +'_'+ l +'" data-clipboard-text="'+ $.trim(lines[l].replace(/"/g, '"')) +'" /><span id="copy_'+ i +'_'+ l +'">'+ lines[l] +'</span>');
|
|
|
|
+ } else {
|
|
|
|
+ theElement.append(lines[l]);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ $(document).on('click','input.copy-text',function(){
|
|
|
|
+ theButton = $(this);
|
|
|
|
+ $('input.copy-text').attr('src','images/clipboard.png');
|
|
|
|
+ $('span.copy-animation,span.copy-animation-ps').removeClass('copy-animation copy-animation-ps');
|
|
|
|
+ try {
|
|
|
|
+ if($('#'+ theButton.attr('rel')).parent('div').hasClass('PS')){
|
|
|
|
+ $('#'+ theButton.attr('rel')).addClass('copy-animation-ps');
|
|
|
|
+ } else if($('#'+ theButton.attr('rel')).parent('div').hasClass('CMD')){
|
|
|
|
+ $('#'+ theButton.attr('rel')).addClass('copy-animation-cmd');
|
|
|
|
+ } else {
|
|
|
|
+ $('#'+ theButton.attr('rel')).addClass('copy-animation');
|
|
|
|
+ }
|
|
|
|
+ navigator.clipboard.writeText(theButton.data('clipboard-text').replace(/<[^>]*>?/gm, ''));
|
|
|
|
+ theButton.attr('src','images/clipboard_active.png');
|
|
|
|
+ } catch(err) {
|
|
|
|
+ }
|
|
|
|
+ return false;
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ $(document).on('click','input.completeBox',function(){
|
|
|
|
+ theBox = $(this);
|
|
|
|
+ $('#'+ theBox.attr('rel')).addClass('strikethrough');
|
|
|
|
+ theBox.prop('disabled',true);
|
|
|
|
+ theBox.parent('li').prevAll().each(function(i,e){
|
|
|
|
+ theLI = $(this);
|
|
|
|
+ if(theLI.find('input[type=checkbox]').not(':checked')){
|
|
|
|
+ $('#'+ theLI.find('input[type=checkbox]').attr('rel')).addClass('strikethrough');
|
|
|
|
+ theLI.find('input[type=checkbox]').prop('checked',true).prop('disabled',true);
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ if(window.self !== window.top){
|
|
|
|
+ window.parent.$('iframe.stepsFrame').height((this['scrollingElement']['scrollHeight']+20) +'px');
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ </script>
|
|
|
|
+ <link href="css/steps.css" rel="stylesheet" type="text/css" />
|
|
|
|
+ </head>
|
|
|
|
+ <body>
|
|
|
|
+ <div id="gridContainer">
|
|
|
|
+ <div class="topMargin"></div>
|
|
|
|
+ <div id="listName" class="topMargin">
|
|
|
|
+ <h1>Installing Passbolt on Linux (Debian 10)</h1>
|
|
|
|
+ </div>
|
|
|
|
+ <div></div>
|
|
|
|
+ <div id="content">
|
|
|
|
+ <ol>
|
|
|
|
+ <li>Log into the Debian device</li>
|
|
|
|
+ <li>Run the following commands in a terminal:
|
|
|
|
+ <div class="codeBlock"># update software repositories<br />
|
|
|
|
+ sudo apt update<br />
|
|
|
|
+ # install available updates<br />
|
|
|
|
+ sudo apt upgrade -y<br />
|
|
|
|
+ # install some dependencies<br />
|
|
|
|
+ sudo apt install git composer apt-transport-https ca-certificates curl gnupg-agent software-properties-common -y<br />
|
|
|
|
+ # install Apache HTTPD and MySQL<br />
|
|
|
|
+ sudo apt install apache2 mariadb-server mariadb-client -y<br />
|
|
|
|
+ # install PHP components<br />
|
|
|
|
+ sudo apt install php7.3 libapache2-mod-php7.3 php-imagick php-gnupg php7.3-common php7.3-mysql php7.3-fpm php7.3-ldap php7.3-gd php7.3-imap php7.3-json php7.3-curl php7.3-zip php7.3-xml php7.3-mbstring php7.3-bz2 php7.3-intl php7.3-gmp php7.3-xsl -y<br />
|
|
|
|
+ # configure the MySQL database<br />
|
|
|
|
+ sudo su<br />
|
|
|
|
+ mysql_secure_installation</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Press Enter to login as root</li>
|
|
|
|
+ <li>Type Y and press Enter to set a root password, type the password twice to confirm</li>
|
|
|
|
+ <li>Type Y and press Enter to remove anonymous users</li>
|
|
|
|
+ <li>Type Y and press Enter to disallow root login remotely</li>
|
|
|
|
+ <li>Type Y and press Enter to remove the test database</li>
|
|
|
|
+ <li>Type Y and press Enter to reload privilege tables</li>
|
|
|
|
+ <li>Run the following command to login into MySQL:
|
|
|
|
+ <div class="codeBlock">mysql -u root -p</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Authenticate with the root password set earlier</li>
|
|
|
|
+ <li>Run the following commands to create the Passbolt database and database user
|
|
|
|
+ <div class="codeBlock">CREATE DATABASE passbolt DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;<br />
|
|
|
|
+ GRANT ALL ON passbolt.* TO 'passboltuser'@'localhost' IDENTIFIED BY 'Pa$$b0lt!!';<br />
|
|
|
|
+ FLUSH PRIVILEGES;<br />
|
|
|
|
+ EXIT;<br />
|
|
|
|
+ exit</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Continue with the following commands to download and extract Passbolt in the Apache webroot
|
|
|
|
+ <div class="codeBlock">cd /var/www<br />
|
|
|
|
+ # clone passbolt from github<br />
|
|
|
|
+ sudo git clone https://github.com/passbolt/passbolt_api.git<br />
|
|
|
|
+ # rename extracted folder passbolt<br />
|
|
|
|
+ sudo mv /var/www/passbolt* /var/www/passbolt<br />
|
|
|
|
+ # set the owner of the new passbolt directory to www-data<br />
|
|
|
|
+ sudo chown -R www-data:www-data /var/www/passbolt<br />
|
|
|
|
+ # setup composer working directory<br />
|
|
|
|
+ sudo mkdir /var/www/.composer<br />
|
|
|
|
+ sudo chown -R www-data:www-data /var/www/.composer<br />
|
|
|
|
+ cd /var/www/passbolt<br />
|
|
|
|
+ # install dependencies with composer, answer y to default permissions<br />
|
|
|
|
+ sudo -u www-data composer install --no-dev<br />
|
|
|
|
+ # generate a key pair<br />
|
|
|
|
+ gpg --gen-key</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Enter a name and email address</li>
|
|
|
|
+ <li>Type O for Okay > Press Enter</li>
|
|
|
|
+ <li>When prompted, leave the passwords blank</li>
|
|
|
|
+ <li>Continue the installation with the following commands in terminal
|
|
|
|
+ <div class="codeBlock"># export the private key, replace email with the email used to create the key pair above<br />
|
|
|
|
+ gpg --armor --export-secret-keys i12bretro@i12bretro.local | sudo tee /var/www/passbolt/config/gpg/serverkey_private.asc > /dev/null<br />
|
|
|
|
+ # export the public key, replace email with the email used to create the key pair above<br />
|
|
|
|
+ gpg --armor --export i12bretro@i12bretro.local | sudo tee /var/www/passbolt/config/gpg/serverkey.asc > /dev/null<br />
|
|
|
|
+ # setup gnupg working directory<br />
|
|
|
|
+ sudo mkdir /var/www/.gnupg<br />
|
|
|
|
+ sudo chown -R www-data:www-data /var/www/.gnupg<br />
|
|
|
|
+ # initialize the keyring for www-data<br />
|
|
|
|
+ sudo su -s /bin/bash -c "gpg --list-keys" www-data<br />
|
|
|
|
+ # create a copy of the configuration template file<br />
|
|
|
|
+ cd /var/www/passbolt/<br />
|
|
|
|
+ sudo cp config/passbolt.default.php config/passbolt.php<br />
|
|
|
|
+ # display the GPG key fingerprint, update the email to what was used above, copy the output to the clipboard<br />
|
|
|
|
+ gpg --list-keys --fingerprint | grep -i -B 2 'i12bretro@i12bretro.local'<br />
|
|
|
|
+ # edit the passbolt config file<br />
|
|
|
|
+ sudo nano config/passbolt.php</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Press CTRL + W and search for fullBaseUrl</li>
|
|
|
|
+ <li>Update the URL to http://DNSorIP/passbolt</li>
|
|
|
|
+ <li>Press CTRL + W and search for Database configuration</li>
|
|
|
|
+ <li>Update the database connection information
|
|
|
|
+ <p>host: localhost<br />
|
|
|
|
+ username: passboltuser<br />
|
|
|
|
+ password: Pa$$b0lt!!<br />
|
|
|
|
+ database: passbolt</p>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Press CTRL + W and search for Email configuration</li>
|
|
|
|
+ <li>Update the email server configuration and default sender account</li>
|
|
|
|
+ <li>Press CTRL + W and search for fingerprint</li>
|
|
|
|
+ <li>Paste the fingerprint from the clipboard</li>
|
|
|
|
+ <li>Remove all spaces from the fingerprint</li>
|
|
|
|
+ <li>Uncomment the public and private lines below the fingerprint by deleting //</li>
|
|
|
|
+ <li>Press CTRL + W and search for passbolt</li>
|
|
|
|
+ <li>Paste the following after the 'passbolt' => [ line to disable the SSL requirement<br />
|
|
|
|
+ 'ssl' => [<br />
|
|
|
|
+ 'force' => false,<br />
|
|
|
|
+ ],</li>
|
|
|
|
+ <li>Press CTRL+O, Enter, CTRL+X to write the changes to passbolt.php</li>
|
|
|
|
+ <li>Continue the installation with the following commands
|
|
|
|
+ <div class="codeBlock"># create a passbolt apache2 config<br />
|
|
|
|
+ sudo nano /etc/apache2/sites-available/passbolt.conf</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Paste the following configuration into passbolt.conf
|
|
|
|
+ <p>Alias /passbolt /var/www/passbolt/webroot<br />
|
|
|
|
+ <Directory /var/www/passbolt/webroot><br />
|
|
|
|
+ Options FollowSymLinks MultiViews<br />
|
|
|
|
+ AllowOverride All<br />
|
|
|
|
+ Order allow,deny<br />
|
|
|
|
+ allow from all<br />
|
|
|
|
+ </Directory></p>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Press CTRL+O, Enter, CTRL+X to write the changes to passbolt.conf</li>
|
|
|
|
+ <li>Run the following command to enable the passbolt site
|
|
|
|
+ <div class="codeBlock"># enable apache modules<br />
|
|
|
|
+ sudo a2enmod headers rewrite<br />
|
|
|
|
+ # enable the passbolt site<br />
|
|
|
|
+ sudo a2ensite passbolt.conf<br />
|
|
|
|
+ # restart the apache2 service<br />
|
|
|
|
+ sudo systemctl restart apache2</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>Run the following command to run the passbolt installer
|
|
|
|
+ <div class="codeBlock">sudo su -s /bin/bash -c "./bin/cake passbolt install --force" www-data</div>
|
|
|
|
+ </li>
|
|
|
|
+ <li>When prompted, enter an email address, first name and last name to create an account</li>
|
|
|
|
+ <li>Copy the URL output after the installation completes</li>
|
|
|
|
+ <li>Open a web browser</li>
|
|
|
|
+ <li>Install the Passbolt browser extension</li>
|
|
|
|
+ <li>With the Passbolt extension installed, navigate to the URL copied from the output of the install script</li>
|
|
|
|
+ <li>The Passbolt setup screen should be displayed</li>
|
|
|
|
+ <li>Enter a passphrase to use for the account</li>
|
|
|
|
+ <li>Save the recovery and store it in a safe place > Click the Next button</li>
|
|
|
|
+ <li>Set a color and 3 letter security token > Click the Next button</li>
|
|
|
|
+ <li>Welcome to self-hosted Passbolt Password Vault</li>
|
|
|
|
+</ol>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </body>
|
|
|
|
+ </html>
|
|
|
|
+
|