Updates to documentation, fixes for edit buttons in map shifts, and CORS for local dev and access
This commit is contained in:
37
mkdocs/docs/build/index.md
vendored
37
mkdocs/docs/build/index.md
vendored
@@ -2,13 +2,17 @@
|
||||
|
||||
Welcome to Changemaker-Lite! You're about to reclaim your digital sovereignty and stop feeding your secrets to corporations. This guide will help you set up your own political infrastructure that you actually own and control.
|
||||
|
||||
This documentation is broken into a few sections:
|
||||
This documentation is broken into a few sections, which you can see in the navigation bar to the left:
|
||||
|
||||
- **Build:** Instructions on how to build the cm-lite on your own hardware
|
||||
- **Services:** Overview of all the services that are installed when you install cm-lite
|
||||
- **Configuration:** Information on how to configure all the services that you install in cm-lite
|
||||
- **Manuals:** Manuals on how to use the applications inside cm-lite (with videos!)
|
||||
|
||||
Of course, everything is also searachable, so if you want to find something specific, just use the search bar at the top right.
|
||||
|
||||
If you come across anything that is unclear, please open an issue in the [Git Repository](https://gitea.bnkops.com/admin/changemaker.lite), reach out to us at [admin@thebunkerops.ca](mailto:admin@thebunkerops.ca), or edit it yourself by clicking the pencil icon at the top right of each page.
|
||||
|
||||
## Quick Start
|
||||
|
||||
### Build Changemaker-Lite
|
||||
@@ -20,7 +24,7 @@ cd changemaker.lite
|
||||
```
|
||||
|
||||
!!! warning "Cloudflare Credentials"
|
||||
The config.sh script will ask you for your Cloudflare credentials to get started. You can find more information on how to find this in the [Cloudlflare Configuration](../config/cloudflare-config.md)
|
||||
The config.sh script will ask you for your optional Cloudflare credentials to get started. You can find more information on how to find this in the [Cloudlflare Configuration](../config/cloudflare-config.md)
|
||||
|
||||
|
||||
```
|
||||
@@ -48,6 +52,28 @@ For secure public access, use the production deployment script:
|
||||
./start-production.sh
|
||||
```
|
||||
|
||||
### Map
|
||||
|
||||
Map is the canvassing application that is custom view of nocodb data. Map is best built **after production deployment** to reduce duplicate build efforts.
|
||||
|
||||
Instructions on how to build the map are available in the [map manual](../build/map.md) in the build directory.
|
||||
|
||||
#### Quick Start for Map
|
||||
Get your NocoDB API token and URL, update the .env file in the map directory, and then run:
|
||||
|
||||
```
|
||||
cd map
|
||||
chmod +x build-nocodb.sh # builds the nocodb tables
|
||||
./build-nocodb.sh
|
||||
```
|
||||
Copy the urls of the newly created nocodb views and update the .env file in the map directory with them, and then run:
|
||||
|
||||
```
|
||||
cd map
|
||||
docker compose up -d
|
||||
```
|
||||
|
||||
You Map instance will be available at [http://localhost:3000](http://localhost:3000) or on the domain you set up during production deployment.
|
||||
|
||||
## Why Changemaker Lite?
|
||||
|
||||
@@ -78,8 +104,8 @@ Before we dive into the technical setup, let's be clear about what you're doing
|
||||
|
||||
- **Ubuntu 24.04 LTS (Noble Numbat)** - Recommended and tested
|
||||
|
||||
!!! note "Getting Started on Ubunut"
|
||||
Want some help getting started with a baseline buildout for a Ubunut server? You can use our [BNKops Server Build Script](./server.md)
|
||||
!!! note "Getting Started on Ubuntu"
|
||||
Want some help getting started with a baseline buildout for a Ubuntu server? You can use our [BNKops Server Build Script](./server.md)
|
||||
|
||||
- Other Linux distributions with systemd support
|
||||
- WSL2 on Windows (limited functionality)
|
||||
@@ -100,8 +126,7 @@ Before we dive into the technical setup, let's be clear about what you're doing
|
||||
|
||||
### Software Prerequisites
|
||||
|
||||
!!! tip "Getting Started on Docker"
|
||||
Want some help getting started with a baseline buildout for a Ubunutu server? You can use our [BNKops Server Build Script](./server.md) to roll out a configured server in about 20 mins!
|
||||
Ensure the following software is installed on your system. The [BNKops Server Build Script](./server.md) can help set these up if you're on Ubuntu.
|
||||
|
||||
1. **Docker Engine** (24.0+)
|
||||
|
||||
|
||||
96
mkdocs/docs/build/map.md
vendored
96
mkdocs/docs/build/map.md
vendored
@@ -34,28 +34,80 @@ cd map
|
||||
Update your `.env` file with your NocoDB details, specifically the instance and api token:
|
||||
|
||||
```env
|
||||
# NocoDB API Configuration
|
||||
NOCODB_API_URL=https://your-nocodb-instance.com/api/v1
|
||||
NOCODB_API_TOKEN=your-api-token-here
|
||||
NOCODB_API_URL=[change me]
|
||||
NOCODB_API_TOKEN=[change me]
|
||||
|
||||
# These will be populated after running build-nocodb.sh
|
||||
NOCODB_VIEW_URL=
|
||||
NOCODB_LOGIN_SHEET=
|
||||
NOCODB_SETTINGS_SHEET=
|
||||
# NocoDB View URL is the URL to your NocoDB view where the map data is stored.
|
||||
NOCODB_VIEW_URL=[change me]
|
||||
|
||||
# NOCODB_LOGIN_SHEET is the URL to your NocoDB login sheet.
|
||||
NOCODB_LOGIN_SHEET=[change me]
|
||||
|
||||
# NOCODB_SETTINGS_SHEET is the URL to your NocoDB settings sheet.
|
||||
NOCODB_SETTINGS_SHEET=[change me]
|
||||
|
||||
# NOCODB_SHIFTS_SHEET is the URL to your shifts sheet.
|
||||
NOCODB_SHIFTS_SHEET=[change me]
|
||||
|
||||
# NOCODB_SHIFT_SIGNUPS_SHEET is the URL to your NocoDB shift signups sheet where users can add their own shifts.
|
||||
NOCODB_SHIFT_SIGNUPS_SHEET=[change me]
|
||||
|
||||
# NOCODB_CUTS_SHEET is the URL to your NocoDB Cuts sheet.
|
||||
NOCODB_CUTS_SHEET=[change me]
|
||||
|
||||
DOMAIN=[change me]
|
||||
|
||||
# MkDocs Integration
|
||||
MKDOCS_URL=[change me]
|
||||
MKDOCS_SEARCH_URL=[change me]
|
||||
MKDOCS_SITE_SERVER_PORT=4002
|
||||
|
||||
# Server Configuration
|
||||
PORT=3000
|
||||
NODE_ENV=production
|
||||
SESSION_SECRET=your-secure-random-string
|
||||
|
||||
# Map Defaults (Edmonton, AB)
|
||||
# Session Secret (IMPORTANT: Generate a secure random string for production)
|
||||
SESSION_SECRET=[change me]
|
||||
|
||||
# Map Defaults (Edmonton, Alberta, Canada)
|
||||
DEFAULT_LAT=53.5461
|
||||
DEFAULT_LNG=-113.4938
|
||||
DEFAULT_ZOOM=11
|
||||
|
||||
# Production Settings
|
||||
COOKIE_DOMAIN=.yourdomain.com
|
||||
ALLOWED_ORIGINS=https://map.yourdomain.com,http://localhost:3000
|
||||
# Optional: Map Boundaries (prevents users from adding points outside area)
|
||||
# BOUND_NORTH=53.7
|
||||
# BOUND_SOUTH=53.4
|
||||
# BOUND_EAST=-113.3
|
||||
# BOUND_WEST=-113.7
|
||||
|
||||
# Cloudflare Settings
|
||||
TRUST_PROXY=true
|
||||
COOKIE_DOMAIN=[change me]
|
||||
|
||||
# Update NODE_ENV to production for HTTPS
|
||||
NODE_ENV=production
|
||||
|
||||
# Add allowed origin
|
||||
ALLOWED_ORIGINS=[change me]
|
||||
|
||||
# SMTP Configuration
|
||||
SMTP_HOST=[change me]
|
||||
SMTP_PORT=587
|
||||
SMTP_SECURE=false
|
||||
SMTP_USER=[change me]
|
||||
SMTP_PASS=[change me]
|
||||
EMAIL_FROM_NAME="[change me]"
|
||||
EMAIL_FROM_ADDRESS=[change me]
|
||||
|
||||
# App Configuration
|
||||
APP_NAME="[change me]"
|
||||
|
||||
# Listmonk Configuration
|
||||
LISTMONK_API_URL=[change me]
|
||||
LISTMONK_USERNAME=[change me]
|
||||
LISTMONK_PASSWORD=[change me]
|
||||
LISTMONK_SYNC_ENABLED=true
|
||||
LISTMONK_INITIAL_SYNC=false # Set to true only for first run to sync existing data
|
||||
```
|
||||
|
||||
### 3. Auto-Create Database Structure
|
||||
@@ -86,9 +138,23 @@ After the script completes:
|
||||
Edit your `.env` file and add the table URLs:
|
||||
|
||||
```env
|
||||
NOCODB_VIEW_URL=https://your-nocodb.com/dashboard/#/nc/project-id/locations-table-id
|
||||
NOCODB_LOGIN_SHEET=https://your-nocodb.com/dashboard/#/nc/project-id/login-table-id
|
||||
NOCODB_SETTINGS_SHEET=https://your-nocodb.com/dashboard/#/nc/project-id/settings-table-id
|
||||
# NocoDB View URL is the URL to your NocoDB view where the map data is stored.
|
||||
NOCODB_VIEW_URL=[change me]
|
||||
|
||||
# NOCODB_LOGIN_SHEET is the URL to your NocoDB login sheet.
|
||||
NOCODB_LOGIN_SHEET=[change me]
|
||||
|
||||
# NOCODB_SETTINGS_SHEET is the URL to your NocoDB settings sheet.
|
||||
NOCODB_SETTINGS_SHEET=[change me]
|
||||
|
||||
# NOCODB_SHIFTS_SHEET is the URL to your shifts sheet.
|
||||
NOCODB_SHIFTS_SHEET=[change me]
|
||||
|
||||
# NOCODB_SHIFT_SIGNUPS_SHEET is the URL to your NocoDB shift signups sheet where users can add their own shifts.
|
||||
NOCODB_SHIFT_SIGNUPS_SHEET=[change me]
|
||||
|
||||
# NOCODB_CUTS_SHEET is the URL to your NocoDB Cuts sheet.
|
||||
NOCODB_CUTS_SHEET=[change me]
|
||||
```
|
||||
|
||||
### 6. Build and Deploy
|
||||
|
||||
Reference in New Issue
Block a user