mirror of
https://github.com/bitwarden/help
synced 2025-12-06 00:03:30 +00:00
Install & Deploy - Windows Server 2019 (#766)
* initial draft * task scheduler section
This commit is contained in:
committed by
GitHub
parent
cfca12c815
commit
c534530cad
@@ -6,7 +6,7 @@ featured: true
|
||||
popular: true
|
||||
hidden: false
|
||||
tags: []
|
||||
order: "13"
|
||||
order: "14"
|
||||
redirect_from:
|
||||
- /article/what-hosted-plaforms-are-supported/
|
||||
---
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, admin]
|
||||
order: "09"
|
||||
order: "10"
|
||||
---
|
||||
|
||||
The Bitwarden System Administrator Portal can be used to:
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, backup]
|
||||
order: "07"
|
||||
order: "08"
|
||||
---
|
||||
|
||||
When self-hosting Bitwarden, you are responsible for implementing your own backup procedures in order to keep data safe.
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "04"
|
||||
order: "05"
|
||||
---
|
||||
|
||||
This article defines the certificate options available to Self-hosted instances of Bitwarden. You will select your certificate option during installation. For installation instructions, see [Install and Deploy On-premise]({{site.baseurl}}/article/install-on-premise/).
|
||||
@@ -150,6 +150,20 @@ sudo dpkg-reconfigure ca-certificates
|
||||
sudo update-ca-certificates
|
||||
```
|
||||
|
||||
#### Android
|
||||
|
||||
To trust a self-signed certificate on an Android device, refer to Google's [Add & remove certificates documentation](https://support.google.com/pixelphone/answer/2844832?hl=en){:target="\_blank"}.
|
||||
|
||||
{% callout info %}
|
||||
If you're **not self-hosting** and encounter the following certificate error on your android device:
|
||||
|
||||
```
|
||||
Exception message: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
|
||||
```
|
||||
|
||||
You will need to upload Bitwarden's certificates to your device. Refer to [this community thread](https://community.bitwarden.com/t/android-client-login-bitwarden-https-cert-problem/12132) for help finding the certificates.
|
||||
{% endcallout %}
|
||||
|
||||
## Use no Certificate
|
||||
|
||||
{% callout warning %}
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, environment]
|
||||
order: "11"
|
||||
order: "12"
|
||||
---
|
||||
|
||||
By default, Bitwarden client applications (Browser Extensions, Mobile Apps, etc.) will connect to Bitwarden-hosted servers. Client applications can be configured to connect to your self-hosted Bitwarden instance.
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: true
|
||||
popular: false
|
||||
tags: []
|
||||
order: "10"
|
||||
order: "11"
|
||||
---
|
||||
|
||||
When operating a self-hosted Bitwarden server in a business setting, administrators may want to centrally configure client application settings (particularly, Server URL) before deploying to users with an endpoint management platform.
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "05"
|
||||
order: "06"
|
||||
---
|
||||
|
||||
Some features of Bitwarden are not configured by the `bitwarden.sh` installer. Configure these settings by editing the environment file, located at `./bwdata/env/global.override.env`. `global.override.env` comes pre-baked with configurable variables (see [Included Variables](#included-variables)), however there are additional variables which can be manually added (see [Optional Variables](#optional-variables)).
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, database, mssql]
|
||||
order: "12"
|
||||
order: "13"
|
||||
---
|
||||
|
||||
By default, self-hosted instances of Bitwarden will use a Microsoft SQL Server (MSSQL) database created as a normal part of [installation setup]({{site.baseurl}}/article/install-on-premise/), however you configure Bitwarden to use an external MSSQL database.
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
---
|
||||
layout: article
|
||||
title: Install and Deploy
|
||||
title: Install and Deploy - Linux
|
||||
categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "01"
|
||||
redirect_from:
|
||||
- /article/install-on-premise/
|
||||
---
|
||||
|
||||
This article will walk you through the procedure to install and deploy Bitwarden to your own server. Bitwarden can be installed and deployed on Linux, macOS, and Windows machines.
|
||||
This article will walk you through the procedure to install and deploy Bitwarden to your own Linux Server. Bitwarden can also be installed and deployed on [Windows]({{site.baseurl}}/article/install-on-premise-windows) machines.
|
||||
|
||||
## System Specifications
|
||||
|
||||
Use the following table to check the **Minimum** and **Recommended** specifications when deploying Bitwarden to your own server:
|
||||
|
||||
| |Minimum|Recommended|
|
||||
|----|-------|-----------|
|
||||
|Processor|x64, 1.4GHz|x64, 2GHz dual core|
|
||||
@@ -21,19 +21,22 @@ Use the following table to check the **Minimum** and **Recommended** specificati
|
||||
|Storage|10GB|25GB|
|
||||
|Docker Version|Engine 19+ and Compose 1.24+|Engine 19+ and Compose 1.24+|
|
||||
|
||||
{% callout success %}
|
||||
If you are looking for a quality provider with affordable prices, we recommend **Digital Ocean**.
|
||||
{% endcallout %}
|
||||
|
||||
## TL;DR
|
||||
|
||||
The following is a summary of the Installation Procedure in this article. Links in this section will jump to detailed **Installation Procedure** sections:
|
||||
|
||||
1. [**Configure your Domain**](#configure-your-domain). Set DNS records for a domain name pointing to your machine, and open ports 80 and 443 on the machine.
|
||||
2. [**Install Docker and Docker Compose**](#install-docker-and-docker-compose) on your machine, and complete the optional [**Docker Post-Installation**](#docker-post-installation-linux-only).
|
||||
2. [**Install Docker and Docker Compose**](#install-docker-and-docker-compose) on your machine.
|
||||
3. [**Create a Bitwarden User & Directory**](#create-bitwarden-local-user--directory) from which to complete installation.
|
||||
3. Retrieve an installation id and key from [**https://bitwarden.com/host**](https://bitwarden.com/host){:target="_blank"} for use in installation.
|
||||
|
||||
For more information, see [What are my installation id and installation key used for?]({{site.baseurl}}/article/hosting-faqs/#general).
|
||||
4. [**Install Bitwarden**](#install-bitwarden) on your machine.
|
||||
5. [**Configure your Environment**](#configure-your-environment) by adjusting settings in `./bwdata/env/global.override.env`.
|
||||
5. [**Configure your Environment**](#post-install-configuration) by adjusting settings in `./bwdata/env/global.override.env`.
|
||||
{% callout success %}At a minimum, configure the `globalSettings__mail__smtp...` variables to setup an email server for inviting and verifying users.{% endcallout %}
|
||||
6. [**Start your instance**](#start-bitwarden).
|
||||
6. Test your installation by opening your configured domain in a Web Browser.
|
||||
@@ -44,26 +47,22 @@ The following is a summary of the Installation Procedure in this article. Links
|
||||
|
||||
By default, Bitwarden will be served through ports 80 (`http`) and 443 (`https`) on the host machine. Open these ports so that Bitwarden can be accessed from within and/or outside of the network. You may opt to choose different ports during installation.
|
||||
|
||||
{% callout success %}
|
||||
**If you're using Windows Firewall**, Docker Desktop for Windows will not automatically add an exception for itself in Windows Firewall. Add exceptions for TCP ports 80 and 443 (or chosen alternative ports) to prevent some errors.
|
||||
{% endcallout %}
|
||||
|
||||
Bitwarden recommends configuring a domain name with DNS records that point to your host machine (for example, `bitwarden.example.com`), especially if you are serving Bitwarden over the internet.
|
||||
We recommend configuring a domain name with DNS records that point to your host machine (for example, `bitwarden.example.com`), especially if you are serving Bitwarden over the internet.
|
||||
|
||||
### Install Docker and Docker Compose
|
||||
|
||||
Bitwarden will be deployed and run on your machine using an array of [Docker containers](https://docs.docker.com/get-started/){:target="_blank"}. Bitwarden can be run with any Docker Edition or plan. Evaluate which edition is best for your installation.
|
||||
|
||||
Deployment of containers is orchestrated using [Docker Compose](https://docs.docker.com/compose/){:target="_blank"}. Some Docker installations, including Windows and macOS, come with Docker Compose already installed.
|
||||
Deployment of containers is orchestrated using [Docker Compose](https://docs.docker.com/compose/){:target="_blank"}. Some Docker installations, including Docker for macOS, come with Docker Compose already installed.
|
||||
|
||||
**Install Docker and Docker Compose on your machine before proceeding with installation.** Refer to the following Docker documentation for help:
|
||||
|
||||
- [Install Docker Engine](https://docs.docker.com/engine/installation/){:target="_blank"}
|
||||
- [Install Docker Compose](https://docs.docker.com/compose/install/){:target="_blank"}
|
||||
|
||||
### Docker Post-Installation (*Linux Only*)
|
||||
### Create Bitwarden Local User & Directory
|
||||
|
||||
Bitwarden recommends configuring your Linux server with a dedicated `bitwarden` service account, from which to install and run Bitwarden. Doing so will isolate your bitwarden instance from other applications running on your server.
|
||||
We recommend configuring your Linux server with a dedicated `bitwarden` service account, from which to install and run Bitwarden. Doing so will isolate your Bitwarden instance from other applications running on your server.
|
||||
|
||||
**These steps are Bitwarden-recommended best practices, but are not required.** For more information, see Docker's [Post-installation steps for Linux](https://docs.docker.com/engine/install/linux-postinstall/){:target="\_blank"} documentation.
|
||||
|
||||
@@ -107,29 +106,21 @@ Bitwarden recommends configuring your Linux server with a dedicated `bitwarden`
|
||||
|
||||
Bitwarden provides a shell script for easy installation on Linux and macOS (Bash), or Windows (PowerShell). Complete the following steps to install Bitwarden using the shell script:
|
||||
|
||||
(*Linux Only*) If you've completed the [Docker Post-Installation](#docker-post-installation) steps, do so as the `bitwarden` user from the `/opt/bitwarden` directory.
|
||||
{% callout success %}
|
||||
If you've [created a Bitwarden User & Directory](#create-bitwarden-local-user--directory), complete the following as the `bitwarden` user from the `/opt/bitwarden` directory.
|
||||
{% endcallout %}
|
||||
|
||||
1. Download the Bitwarden installation script (`bitwarden.sh`) to your machine:
|
||||
|
||||
{% icon fa-linux %} {% icon fa-apple %} Bash
|
||||
|
||||
curl -Lso bitwarden.sh https://go.btwrdn.co/bw-sh \
|
||||
&& chmod 700 bitwarden.sh
|
||||
|
||||
{% icon fa-windows %} PowerShell
|
||||
|
||||
Invoke-RestMethod -OutFile bitwarden.ps1 `
|
||||
-Uri https://go.btwrdn.co/bw-ps
|
||||
```
|
||||
curl -Lso bitwarden.sh https://go.btwrdn.co/bw-sh && chmod 700 bitwarden.sh
|
||||
```
|
||||
|
||||
2. Run the installer script. A `./bwdata` directory will be created relative to the location of `bitwarden.sh`.
|
||||
|
||||
{% icon fa-linux %} {% icon fa-apple %} Bash
|
||||
|
||||
./bitwarden.sh install
|
||||
|
||||
{% icon fa-windows %} PowerShell
|
||||
|
||||
.\bitwarden.ps1 -install
|
||||
```
|
||||
./bitwarden.sh install
|
||||
```
|
||||
|
||||
3. Complete the prompts in the installer:
|
||||
|
||||
@@ -159,29 +150,13 @@ Bitwarden provides a shell script for easy installation on Linux and macOS (Bash
|
||||
|
||||
If you specify `n`, your instance will not use an SSL certificate and you will be required to front your installation with a HTTPS proxy, or else Bitwarden applications will not function properly.
|
||||
|
||||
### Configure your Environment
|
||||
### Post-Install Configuration
|
||||
|
||||
Configuring your environment involves two procedures; Installation Configuration and Environment Variable Configuration. The degree to which you will be required to configure your environment will depend on your unique needs.
|
||||
Configuring your environment can involve making changes to two files; an [environment variables file](#environment-variables) and an [installation file](#installation-configuration):
|
||||
|
||||
#### Installation Configuration
|
||||
#### Environment Variables (*Required*)
|
||||
|
||||
The Bitwarden installation script uses settings in `./bwdata/config.yml` to generate the necessary assets for installation. Some installation scenarios (e.g. installations behind a proxy with alternate ports) may require adjustments to `config.yml` that were not provided during standard installation.
|
||||
|
||||
Edit `config.yml` as necessary, and apply changes using one of the following commands:
|
||||
|
||||
{% icon fa-linux %} {% icon fa-apple %} Bash
|
||||
|
||||
./bitwarden.sh rebuild
|
||||
|
||||
{% icon fa-windows %} PowerShell
|
||||
|
||||
.\bitwarden.ps1 -rebuild
|
||||
|
||||
#### Environment Variables
|
||||
|
||||
Some features of Bitwarden are not configured by the `bitwarden.sh` installer. Configure these settings by editing the environment file, located at `./bwdata/env/global.override.env`.
|
||||
|
||||
**At a minimum, you should replace the values for:**
|
||||
Some features of Bitwarden are not configured by the `bitwarden.sh` script. Configure these settings by editing the environment file, located at `./bwdata/env/global.override.env`. **At a minimum, you should replace the values for:**
|
||||
|
||||
```
|
||||
...
|
||||
@@ -192,36 +167,34 @@ globalSettings__mail__smtp__username=<placeholder>
|
||||
globalSettings__mail__smtp__password=<placeholder>
|
||||
...
|
||||
adminSettings__admins=
|
||||
...
|
||||
```
|
||||
|
||||
Replacing `globalSettings__mail__smtp...=` placeholders will configure the SMTP Mail Server settings that will be used to verify new users and send invitations.
|
||||
Replacing `globalSettings__mail__smtp...=` placeholdesr will configure the SMTP Mail Server that will be used to send verification emails to new users and invitations to Organizations. Adding an email address to `adminSettings__admins=` will provision access to the Admin Portal.
|
||||
|
||||
Adding an email address to `adminSettings__admins=` will provision access to the Admin Portal.
|
||||
After editing `global.override.env`, run the following command to apply your changes:
|
||||
|
||||
After editing `global.override.env`, run one of the following commands to apply your changes:
|
||||
```
|
||||
./bitwarden.sh restart
|
||||
```
|
||||
|
||||
{% icon fa-linux %} {% icon fa-apple %} Bash
|
||||
#### Installation File
|
||||
|
||||
./bitwarden.sh restart
|
||||
The Bitwarden installation script uses settings in `./bwdata/config.yml` to generate the necessary assets for installation. Some installation scenarios (e.g. installations behind a proxy with alternate ports) may require adjustments to `config.yml` that were not provided during standard installation.
|
||||
|
||||
{% icon fa-windows %} PowerShell
|
||||
Edit `config.yml` as necessary and apply your changes by running:
|
||||
|
||||
.\bitwarden.ps1 -restart
|
||||
|
||||
For more information about configuring Environment Variables, see [Configure Environment Variables]({{site.baseurl}}/article/environment-variables/).
|
||||
```
|
||||
./bitwarden.sh rebuild
|
||||
```
|
||||
|
||||
### Start Bitwarden
|
||||
|
||||
Once you've completed all previous steps, start your Bitwarden instance:
|
||||
|
||||
{% icon fa-linux %} {% icon fa-apple %} Bash
|
||||
|
||||
./bitwarden.sh start
|
||||
|
||||
{% icon fa-windows %} PowerShell
|
||||
|
||||
.\bitwarden.ps1 -start
|
||||
|
||||
```
|
||||
./bitwarden.sh start
|
||||
```
|
||||
|
||||
{% callout info %}
|
||||
The first time you start Bitwarden it may take some time as it downloads all of the images from Docker Hub.
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "02"
|
||||
order: "03"
|
||||
---
|
||||
This article will walk you through the procedure to manually install and deploy Bitwarden to your own server. **Installation using the Bitwarden installation script is recommended for most users, for instructions see [Install and Deploy]({{site.baseurl}}/article/install-on-premise/)**.
|
||||
|
||||
|
||||
232
_articles/hosting/install-on-premise-windows.md
Normal file
232
_articles/hosting/install-on-premise-windows.md
Normal file
@@ -0,0 +1,232 @@
|
||||
---
|
||||
layout: article
|
||||
title: Install and Deploy - Windows
|
||||
categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "02"
|
||||
---
|
||||
|
||||
This article will walk you through the procedure to install and deploy Bitwarden to your own Windows Server. Bitwarden can also be installed and deployed on [Linux and macOS]({{site.baseurl}}/article/install-on-premise/) machines.
|
||||
|
||||
## System Specifications
|
||||
|
||||
| |Minimum|Recommended|
|
||||
|-|-------|-----------|
|
||||
|Processor|x64, 1.4GHz|x64, 2GHz Dual Core|
|
||||
|Memory|6GB RAM|8+ GB RAM|
|
||||
|Storage|10GB|25GB|
|
||||
|Docker Version|Engine 19+ and Compose 1.24+|Engine 19+ and Compose 1.24+|
|
||||
|
||||
### Nested Virtualization
|
||||
|
||||
Running Bitwarden on a Windows Server **requires use of Nested Virtualization**. Please check your Hypervisor's documentation to find out if Nested Virtualization is supported and how to enable it.
|
||||
|
||||
{% callout success %}
|
||||
If you're running the Windows Server as an Azure VM, we recommend a **Standard D2s v3 Virtual Machine running Windows Server 2019 Gen2**, which meets all [system requirements](#system-specifications) including support for Nested Virtualization.
|
||||
{% endcallout %}
|
||||
|
||||
## TL;DR
|
||||
|
||||
The following is a summary of the [Installation Procedure](#installation-procedure) in this article. Links in this section will jump to detailed **Installation Procedure** sections:
|
||||
|
||||
1. [**Configure your Domain**](#configure-your-domain). Set DNS records for a domain name pointing to your machine, and open ports 80 and 443 on the machine.
|
||||
2. [**Install and Setup Docker Desktop**](#setup-docker-desktop) on your machine.
|
||||
3. [**Create a Bitwarden User & Directory**](#create-bitwarden-local-user--directory) from which to complete the installation.
|
||||
4. Retrieve an installation id and key from [**https://bitwarden.com/host**](https://bitwarden.com/host){:target="_blank"} for use in installation.
|
||||
|
||||
For more information, see [What are my installation id and installation key used for?]({{site.baseurl}}/article/hosting-faqs/#general).
|
||||
5. [**Install Bitwarden**](#install-bitwarden) on your machine.
|
||||
6. [**Configure your Environment**](#post-install-configuration) by adjusting settings in `\bwdata\env\global.override.env`.
|
||||
{% callout success %}At a minimum, configure the `globalSettings__mail__smtp...` variables to setup an email server for inviting and verifying users.{% endcallout %}
|
||||
7. [**Start your instance**](#start-bitwarden).
|
||||
8. Test your installation by opening your configured domain in a Web Browser.
|
||||
|
||||
## Installation Procedure
|
||||
|
||||
### Configure your Domain
|
||||
|
||||
By default, Bitwarden will be served through ports 80 (`http`) and 443 (`https`) on the host machine. Open these ports so that Bitwarden can be accessed from within and/or outside of the network. You may opt to choose different ports during installation.
|
||||
|
||||
{% callout success %}
|
||||
**If you're using Windows Firewall**, Docker Desktop for Windows will not automatically add an exception for itself in Windows Firewall. Add exceptions for TCP ports 80 and 443 (or chosen alternative ports) to prevent some errors.
|
||||
{% endcallout %}
|
||||
|
||||
We recommend configuring a domain name with DNS records that point to your host machine (for example, `bitwarden.example.com`), especially if you are serving Bitwarden over the internet.
|
||||
|
||||
### Setup Docker Desktop
|
||||
|
||||
Bitwarden will be deployed and run on your machine using an array of [Docker containers](https://docs.docker.com/get-started/){:target="_blank"}. Docker Desktop for Windows includes both Docker Engine and Docker Compose. Download and install [Docker Desktop for Windows](https://docs.docker.com/desktop/windows/install/){:target="\_blank"} and check the **Enable Hyper-V Windows Features** configuration option during installation.
|
||||
|
||||
### Create Bitwarden Local User & Directory
|
||||
|
||||
Open PowerShell and create a Bitwarden local user by running the following commands:
|
||||
|
||||
```
|
||||
PS C:\> $Password = Read-Host -AsSecureString
|
||||
```
|
||||
After running the above command, enter the desired password in the text input dialog. After specifying a password, run the following:
|
||||
```
|
||||
New-LocalUser "Bitwarden" -Password $Password -Description "Bitwarden Local Admin"
|
||||
```
|
||||
|
||||
As the newly created user, create a Bitwarden folder under `C:\`:
|
||||
|
||||
```
|
||||
PS C:\> mkdir Bitwarden
|
||||
```
|
||||
|
||||
In Docker Desktop, navigate to **Settings** → **Resources** → **File Sharing** and add the created directory (`C:\Bitwarden`) to the Resources list. Select **Apply & Restart** to apply your changes.
|
||||
|
||||
### Install Bitwarden
|
||||
|
||||
Bitwarden provides a Powershell Cmdlet file (`.ps1`) for easy installation on Windows machines. Complete the following steps to install Bitwarden using the Cmdlet:
|
||||
|
||||
{% callout success %}
|
||||
If you've [created a Bitwarden User & Directory](#create-bitwarden-local-user--directory), complete the following as the `Bitwarden` user.
|
||||
{% endcallout %}
|
||||
|
||||
1. Navigate to the [created](#create-bitwarden-local-user--directory) directory:
|
||||
|
||||
```
|
||||
cd C:\Bitwarden
|
||||
```
|
||||
1. Run the following command to download the Bitwarden installation script (`bitwarden.ps1`):
|
||||
|
||||
```
|
||||
Invoke-RestMethod -OutFile bitwarden.ps1 -Uri https://go.btwrdn.co/bw-ps
|
||||
```
|
||||
2. Run the installer script using the following command:
|
||||
|
||||
```
|
||||
.\bitwarden.ps1 -install
|
||||
```
|
||||
3. Complete the prompts in the installer:
|
||||
|
||||
- **Enter the domain name for your Bitwarden instance:**
|
||||
|
||||
Typically, this value should be the configured DNS record.
|
||||
- **Do you want to use Let's Encrypt to generate a free SSL certificate? (y/n):**
|
||||
|
||||
Specify `y` to generate a trusted SSL certificate using Let's Encrypt. You will be prompted to enter an email address for expiration reminders from Let's Encrypt. For more information, see [Certificate Options]({{site.baseurl}}/article/certificates/).
|
||||
|
||||
Alternatively, specify `n` and use the **Do you have a SSL certificate to use?** option.
|
||||
- **Enter your installation id:**
|
||||
|
||||
Retrieve an installation id using a valid email at [https://bitwarden.com/host](https://bitwarden.com/host){:target="\_blank"}. For more information, see [What are my installation id and installation key used for?]({{site.baseurl}}/article/hosting-faqs/#q-what-are-my-installation-id-and-installation-key-used-for).
|
||||
- **Enter your installation key:**
|
||||
|
||||
Retrieve an installation key using a valid email at [https://bitwarden.com/host](https://bitwarden.com/host){:target="\_blank"}. For more information, see [What are my installation id and installation key used for?]({{site.baseurl}}/article/hosting-faqs/#q-what-are-my-installation-id-and-installation-key-used-for).
|
||||
- **Do you have a SSL certificate to use? (y/n)**
|
||||
|
||||
If you already have your own SSL certificate, specify `y` and place the necessary files in the `C:\Bitwarden\bwdata\ssl\<your_domain>` directory. You will be asked whether it is a trusted SSL certificate (`y/n`). For more information, see [Certificate Options]({{site.baseurl}}/article/certificates/).
|
||||
|
||||
Alternatively, specify `n` and use the **self-signed SSL certificate?** option, which is only recommended for testing purposes.
|
||||
- **Do you want to generate a self-signed SSL certificate? (y/n)**:
|
||||
|
||||
Specify `y` to have Bitwarden generate a self-signed certificate for you. This option is only recommended for testing. For more information, see [Certificate Options]({{site.baseurl}}/article/certificates/).
|
||||
|
||||
If you specify `n`, your instance will not use an SSL certificate and you will be required to front your installation with an HTTPS proxy, or else Bitwarden applications will not function properly.
|
||||
|
||||
### Post-Install Configuration
|
||||
|
||||
Configuring your environment can involve making changes to two files; an [environment variables file](#environment-variables) and an [installation file](#installation-configuration):
|
||||
|
||||
#### Environment Variables (*Required*)
|
||||
|
||||
Some features of Bitwarden are not configured by the `bitwarden.ps1` Cmdlet. Configure these settings by editing the environment file, located at `\bwdata\env\global.override.env`. **At a minimum, you should replace the values for:**
|
||||
|
||||
```
|
||||
...
|
||||
globalSettings__mail__smtp__host=<placeholder>
|
||||
globalSettings__mail__smtp__port=<placeholder>
|
||||
globalSettings__mail__smtp__ssl=<placeholder>
|
||||
globalSettings__mail__smtp__username=<placeholder>
|
||||
globalSettings__mail__smtp__password=<placeholder>
|
||||
...
|
||||
adminSettings__admins=
|
||||
...
|
||||
```
|
||||
|
||||
Replacing `globalSettings__mail__smtp...=` placeholdesr will configure the SMTP Mail Server that will be used to send verification emails to new users and invitations to Organizations. Adding an email address to `adminSettings__admins=` will provision access to the Admin Portal.
|
||||
|
||||
After editing `global.override.env`, run the following command to apply your changes:
|
||||
|
||||
```
|
||||
.\bitwarden.ps1 -restart
|
||||
```
|
||||
|
||||
#### Installation File
|
||||
|
||||
The Bitwarden installation script uses settings in `.\bwdata\config.yml` to generate the necessary assets for installation. Some installation scenarios (e.g. installations behind a proxy with alternate ports) may require adjustments to `config.yml` that were not provided during standard installation.
|
||||
|
||||
Edit `config.yml` as necessary and apply your changes by running:
|
||||
|
||||
```
|
||||
.\bitwarden.psq -rebuild
|
||||
```
|
||||
|
||||
### Start Bitwarden
|
||||
|
||||
Once you've completed all previous steps, start your Bitwarden instance by running the following command:
|
||||
|
||||
```
|
||||
.\bitwarden.ps1 -start
|
||||
```
|
||||
|
||||
{% callout info %}
|
||||
The first time you start Bitwarden it may take some time as it downloads images from Docker Hub.
|
||||
{% endcallout %}
|
||||
|
||||
Verify that all containers are running correctly:
|
||||
|
||||
```
|
||||
docker ps
|
||||
```
|
||||
|
||||
{% image hosting/docker-ps-win.png List showing Healthy Containers %}
|
||||
|
||||
Congratulations! Bitwarden is now up and running at `https://your.domain.com`. Visit the web vault in your web browser to confirm that it’s working.
|
||||
|
||||
You may now register a new account and log in. You will need to have configured `smtp` environment variables (see [Environment Variables]({{site.baseurl}}/article/environment-variables/)) in order to verify the email for your new account.
|
||||
|
||||
## Start Docker on Boot
|
||||
|
||||
Docker Desktop will only automatically start on boot if you have a logged-in RDP session. To start Docker Desktop on boot regardless of whether there is a user logged in:
|
||||
|
||||
{% callout warning %}
|
||||
Docker Desktop may take up to 15 minutes after boot to fully start and for containers to be accessible from the network.
|
||||
{% endcallout %}
|
||||
|
||||
1. Open Task Scheduler and select **Create Task...** from the Actions menu.
|
||||
2. Configure the task with the following Security options:
|
||||
|
||||
- Set the task to use the [created](#create-bitwarden-local-user--directory) `Bitwarden` user account.
|
||||
- Set the task to **Run whether user is logged on or not**.
|
||||
3. Select the **Triggers** tab and create the following trigger:
|
||||
|
||||
- From the Begin the task dropdown, select **At startup**.
|
||||
- In the Advanced settings section, check the **Delay task for:** checkbox and select **1 minute** from the dropdown.
|
||||
4. Select the **Actions** tab and create the following action:
|
||||
|
||||
- In the Program/script input, specify `"C:\Program Files\Docker\Docker\Docker Desktop.exe"`.
|
||||
5. Select **OK** to finish creating the scheduled task.
|
||||
|
||||
## Script Commands Reference
|
||||
|
||||
The Bitwarden installation script (`bitwarden.ps1`) has the following commands available. All command must be prefixed with a switch (`-`), for example `.\bitwarden.ps1 -start`:
|
||||
|
||||
|Command|Description|
|
||||
|-------|-----------|
|
||||
|-install|Start the installer.|
|
||||
|-start|Start all containers.|
|
||||
|-restart|Restart all containers.|
|
||||
|-stop|Stop all containers.|
|
||||
|-update|Update all containers and the database.|
|
||||
|-updatedb|Update/initialize the database.|
|
||||
|-updateself|Update the installation script.|
|
||||
|-updateconf|Update all containers without restarting the running instance.|
|
||||
|-renewcert|Renew certificates.|
|
||||
|-rebuild|Rebuild generated installation assets from `config.yml`.|
|
||||
|-help|List all commands.|
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, licensing]
|
||||
order: "08"
|
||||
order: "09"
|
||||
---
|
||||
|
||||
Self-hosting Bitwarden is free, however some features must be unlocked in your self-hosted instance with a registered license file. A license file can be obtained from the Bitwarden-hosted [Web Vault]({{site.baseurl}}/article/getting-started-webvault) by either an account with a Premium Individual subscription or by the Owner of an Organization.
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, docker, install, deploy]
|
||||
order: "03"
|
||||
order: "04"
|
||||
---
|
||||
|
||||
This article will walk you through procedures for transitioning from Cloud to Self-hosted, from Self-hosted to Cloud, and from one self-hosted server to another:
|
||||
|
||||
@@ -5,7 +5,7 @@ categories: [hosting]
|
||||
featured: false
|
||||
popular: false
|
||||
tags: [hosting, update]
|
||||
order: "06"
|
||||
order: "07"
|
||||
---
|
||||
|
||||
{% callout success %}
|
||||
|
||||
BIN
images/hosting/docker-ps-win.png
Normal file
BIN
images/hosting/docker-ps-win.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 276 KiB |
Reference in New Issue
Block a user