mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-03 20:06:08 +01:00 
			
		
		
		
	chore(docs): sync
This commit is contained in:
		@@ -7,7 +7,6 @@ I've assumed you have created a DNS A record for `trilium.yourdomain.com` that y
 | 
			
		||||
     docker pull triliumnext/notes:[VERSION]
 | 
			
		||||
     docker create --name trilium -t -p 127.0.0.1:8080:8080 -v ~/trilium-data:/home/node/trilium-data triliumnext/notes:[VERSION]
 | 
			
		||||
    ```
 | 
			
		||||
    
 | 
			
		||||
2.  Configure Apache proxy and websocket proxy
 | 
			
		||||
    
 | 
			
		||||
    1.  Enable apache proxy modules
 | 
			
		||||
@@ -18,7 +17,6 @@ I've assumed you have created a DNS A record for `trilium.yourdomain.com` that y
 | 
			
		||||
         a2enmod proxy_http
 | 
			
		||||
         a2enmod proxy_wstunnel
 | 
			
		||||
        ```
 | 
			
		||||
        
 | 
			
		||||
    2.  Create a new let's encrypt certificate
 | 
			
		||||
        
 | 
			
		||||
        ```
 | 
			
		||||
@@ -26,7 +24,6 @@ I've assumed you have created a DNS A record for `trilium.yourdomain.com` that y
 | 
			
		||||
        ```
 | 
			
		||||
        
 | 
			
		||||
        Choose standalone (2) and note the location of the created certificates (typically /etc/letsencrypt/live/...)
 | 
			
		||||
        
 | 
			
		||||
    3.  Create a new virtual host file for apache (you may want to use `apachectl -S` to determine the server root location, mine is /etc/apache2)
 | 
			
		||||
        
 | 
			
		||||
        ```
 | 
			
		||||
@@ -55,11 +52,8 @@ I've assumed you have created a DNS A record for `trilium.yourdomain.com` that y
 | 
			
		||||
             Include /etc/letsencrypt/options-ssl-apache.conf
 | 
			
		||||
         
 | 
			
		||||
        ```
 | 
			
		||||
        
 | 
			
		||||
    4.  Enable the virtual host with `sudo a2ensite trilium.yourdomain.com.conf`
 | 
			
		||||
        
 | 
			
		||||
    5.  Reload apache2 with `sudo systemctl reload apache2`
 | 
			
		||||
        
 | 
			
		||||
3.  Create and enable a systemd service to start the docker container on boot
 | 
			
		||||
    
 | 
			
		||||
    1.  Create a new empty file called `/lib/systemd/system/trilium.service` with the contents
 | 
			
		||||
@@ -78,7 +72,6 @@ I've assumed you have created a DNS A record for `trilium.yourdomain.com` that y
 | 
			
		||||
         [Install]
 | 
			
		||||
         WantedBy=local.target
 | 
			
		||||
        ```
 | 
			
		||||
        
 | 
			
		||||
    2.  Install, enable and start service
 | 
			
		||||
        
 | 
			
		||||
        ```
 | 
			
		||||
 
 | 
			
		||||
@@ -7,14 +7,12 @@ Configure Nginx proxy and HTTPS. The operating system here is Ubuntu 18.04.
 | 
			
		||||
    sudo apt-get install nginx
 | 
			
		||||
    sudo apt-get remove apache2
 | 
			
		||||
    ```
 | 
			
		||||
    
 | 
			
		||||
2.  Create configure file
 | 
			
		||||
    
 | 
			
		||||
    ```
 | 
			
		||||
    cd /etc/nginx/conf.d
 | 
			
		||||
    vim default.conf
 | 
			
		||||
    ```
 | 
			
		||||
    
 | 
			
		||||
3.  Fill the file with the context shown below, part of the setting show be changed. Then you can enjoy your web with HTTPS forced and proxy.
 | 
			
		||||
    
 | 
			
		||||
    ```
 | 
			
		||||
 
 | 
			
		||||
@@ -20,13 +20,9 @@ TOTP (Time-Based One-Time Password) is a security feature that generates a uniqu
 | 
			
		||||
### TOTP
 | 
			
		||||
 | 
			
		||||
1.  Start Trilium Notes normally.
 | 
			
		||||
    
 | 
			
		||||
2.  Go to "Menu" -> "Options" -> "MFA"
 | 
			
		||||
    
 | 
			
		||||
3.  Click the "Generate TOTP Secret" button
 | 
			
		||||
    
 | 
			
		||||
4.  Copy the generated secret to your authentication app/extension
 | 
			
		||||
    
 | 
			
		||||
5.  Set an environment variable "TOTP\_SECRET" as the generated secret. Environment variables can be set with a .env file in the root directory, by defining them in the command line, or with a docker container.
 | 
			
		||||
    
 | 
			
		||||
    ```
 | 
			
		||||
@@ -45,17 +41,11 @@ TOTP (Time-Based One-Time Password) is a security feature that generates a uniqu
 | 
			
		||||
    # Docker
 | 
			
		||||
    docker run -p 8080:8080 -v ~/trilium-data:/home/node/trilium-data -e TOTP_ENABLED="true" -e TOTP_SECRET="secret" triliumnext/notes:[VERSION]
 | 
			
		||||
    ```
 | 
			
		||||
    
 | 
			
		||||
6.  Restart Trilium
 | 
			
		||||
    
 | 
			
		||||
7.  Go to "Options" -> "MFA"
 | 
			
		||||
    
 | 
			
		||||
8.  Click the "Generate Recovery Codes" button
 | 
			
		||||
    
 | 
			
		||||
9.  Save the recovery codes. Recovery codes can be used once in place of the TOTP if you loose access to your authenticator. After a rerecovery code is used, it will show the unix timestamp when it was used in the MFA options tab.
 | 
			
		||||
    
 | 
			
		||||
10.  Load the secret into an authentication app like google authenticator
 | 
			
		||||
    
 | 
			
		||||
 | 
			
		||||
### OpenID
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user