△ Set up Quartz on a VPS
# Order of operations
# Set up
- Set up the server
- Set up SSH
- via Linode server config
 
- Connect to the server
|  |  | 
# Git
# Set up git server and git clients
- Set up git user
|  |  | 
- Give git user sudo
|  |  | 
- (Give git user ownership over /srv/git)
|  |  | 
- Install git
|  |  | 
- Set up bare repo of Obsidian vault as git server under git user (requires auth token from GitHub)
|  |  | 
- Set up bare repo of hugo site deployment installation as a bare repo under the git user
|  |  | 
- Set up a repo of the hugo-obsidiandeployment installation under the user home directory
|  |  | 
- clear the content folder in that directory and create a new content folder
|  |  | 
|  |  | 
- ==Switch to local computer==
- Clone from git server
|  |  | 
- Make sure ssh is added to the keychain for the server
|  |  | 
- Test an edit: edit a file, then:
|  |  | 
- ==Switch back to the server==
- Switch to git user
|  |  | 
- Confirm changes are made ☑︎
|  |  | 
# Set up Hugo and Quartz
- Update yum
|  |  | 
- Install Go
|  |  | 
- Install Snap and Hugo
- Install hugo-obsidian
|  |  | 
- Set bash profile paths for hugo-obsidian in user directory by adding the following to ~/.bash_profile
|  |  | 
- Add a hugo-obsidiancommand to thepost-receivehook
|  |  | 
- Configure hugo’s ignoreFilesparameter to hide private data:
|  |  | 
- Find the `ignoreFiles` field and add the directories you want to hide. Note that the ignoreFiles values do not recurse over the file structure, so you will have to explicitly list nested folders:
|  |  | 
# Set up the web server
- install nginx
|  |  | 
- set up and configure firewalls
|  |  | 
- install SELinux core policy python utilities
|  |  | 
- configure SELinux security settings
|  |  | 
403 errors? Try invoking the above again.
Certain events (e.g., in the most recent case, restoring my server from a backup) cause the above permissions to be reset.
This can cause 403 errors and hours of muttering “wtf” before realizing that the above
chconcommands need to be re-run. 🤦♂️
- configure nginx user permissionsedit: I don’t think this is necessary anymore.- ensure 
nginx user has permissions to /home/git/pyroclast/public- added nginx to the same user group as the user creating content
 
 
- ensure 
nginx user has permissions to 
|  |  | 
- configure nginx sites
|  |  | 
- add a basic server config file. certbotwill make it more robust later
|  |  | 
- config file:
|  |  | 
- symlink site configs:
|  |  | 
- set up the NGINX configuration file
|  |  | 
- Add:
|  |  | 
- set up the hugo config
- update baseURL in config.toml(e.g.,baseURL = "https://fulcra.design")
- update names and other details in data/config.yaml
 
- update baseURL in 
# Set up the domain
- Set up the domain on the VPS
- Follow your provider’s instructions
 
- Set up redirects from previous blog posts to new URL slugs
# Set up HTTPS
- Install certbot
|  |  | 
- Run certbot
|  |  | 
- Go through the config options in the command line
- Restart nginx
|  |  | 
# Set up restricted access or password sections
# Style the site
- Configure colours
- Edit /assets/styles/custom
 
- Edit 
- Add menus
- Use Hugo menus
 
# Set up writing environments
# Set up Obsidian on macOS
- Open folder as vault → select the folder containing the notes repo
- Settings → Files & Links → New Link Format → Relative path to file
- set up a Keyboard Maestro macro that automatically pulls and pushes every time Obsidian is opened
# Set up Obsidian on iOS and iPadOS
- Create a new vault in Obsidian not on iCloud
# Set up mobile git
- In Working Copy, select “Link to external repository” and select the recently created blank vault
- Add the git server remote to the new repo
- Add Working Copy’s public SSH key to the server’s ./ssh/authorized-keys
- Pull changes
- Switch the vault’s config profile to .iosor whatever you prefer
- Set up a Shortcuts automation that runs whenever Obsidian is opened or closed that pulls from remote and pushes anything changed
# Switch automations
- Reconfigure any automations that previously depended on the vault name or path. Possibilities include:
- URL schemes
- Shortcuts
- Keyboard Maestro
- Hazel
- DEVONthink
 
