Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge Upstream Changes #2

Merged
merged 137 commits into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
137 commits
Select commit Hold shift + click to select a range
d2b8d2e
[#20241018] Fix SimpleModal icon
delano Oct 18, 2024
af460a9
[#20241018] Separate domain logic into separate files
delano Oct 18, 2024
a6fc9ad
[#20241018] Add domain brand settings view
delano Oct 18, 2024
537d403
[#20241018] 14:14
delano Oct 18, 2024
1e35842
[#20241018] Update account form template and remove redundant link
delano Oct 18, 2024
c7d956d
[#20241018] 14:47
delano Oct 18, 2024
1b5cfa1
[#20241018] 15:10
delano Oct 18, 2024
62d77ca
[#20241018] 15:34 & 16:04 (got distracted fixes type error)
delano Oct 18, 2024
9c84856
[#20241018] 16:06
delano Oct 18, 2024
72c718e
[#20241018] 16:51 (working, with inline image)
delano Oct 18, 2024
fe245da
[#20241018] Add UI/UX for brand customization
delano Oct 19, 2024
c7146af
[#20241018] Enhances domain branding form functionality
delano Oct 19, 2024
d69b991
[#20241018] Add DELETE method for removing logo
delano Oct 19, 2024
0dd20f8
[#20241018] Polish domain brand UI/UX
delano Oct 19, 2024
ff34a84
[#20241018] Polishing the domains list view
delano Oct 19, 2024
800ce24
[#20241018] Add brand preview in account settings
delano Oct 19, 2024
aed7baa
[#20241018] Merge branch 'develop' into delano/20241018-logo
delano Oct 23, 2024
d913ef8
[#20241018] Fix for displaying logo when updated
delano Oct 23, 2024
0c61a33
[#20241018] Formatting (no functionality)
delano Oct 23, 2024
eef2538
[#20241018] Give the domains page a minimum height
delano Oct 23, 2024
4bb2eef
[#20241018] Fix for displaying domain status at all sizes
delano Oct 23, 2024
6e8eb8b
[#20241018] Merge branch 'develop' into delano/20241018-logo
delano Oct 27, 2024
958afd0
[#20241018] Update new routes with multi-component
delano Oct 27, 2024
34df586
[#20241018] Give Onetime::Problem classes a message by default
delano Oct 27, 2024
efee613
[#20241018] Update error handling in web application
delano Oct 27, 2024
15f4df2
[#20241018] Add GetImage functionality to domain logic
delano Oct 27, 2024
85919ea
[#20241018] Adds image serving endpoint
delano Oct 27, 2024
a56cfc6
[#20241018] Update API utils to use shrimp header
delano Oct 27, 2024
9290de9
[#20241018] Fix fir missing brand frontend path
delano Oct 27, 2024
efb52b7
[#20241018] Fix for dashboard nav active subpages
delano Oct 27, 2024
2d00ddc
[#20241018] Restyled brand form layout
delano Oct 27, 2024
3ce8c38
[#20241018] Fix for brand param names
delano Oct 27, 2024
d78fa0e
[#20241018] From side by side to vertical layout
delano Oct 27, 2024
2882a26
[#20241018] Add StatusBar component for form feedback
delano Oct 28, 2024
aa0f6c1
[#20241018] Replace basic alerts with StatusBar
delano Oct 28, 2024
8fcdd33
[#20241018] Fix incorrect passphrase handling
delano Oct 28, 2024
d811676
[#20241018] Refactor BurnSecrets to use StatusBar component
delano Oct 28, 2024
ad7582c
[#20241018] Update branding UI layout
delano Oct 28, 2024
d3ab4ec
[#20241018] Update web routes definition
delano Oct 28, 2024
881aa34
[#20241018] Another go at Docker image tagging strategy
delano Oct 28, 2024
34b1fea
Bump rexml from 3.3.8 to 3.3.9 in the bundler group
dependabot[bot] Oct 28, 2024
29e4b3c
Bump @playwright/test from 1.47.2 to 1.48.2
dependabot[bot] Oct 28, 2024
0fee204
[#20241018] Merge branch 'develop' into delano/20241018-logo
delano Oct 28, 2024
4d8f7f0
[#20241018] Simplify AuthView layout
delano Oct 29, 2024
1326999
[#20241018] Update title
delano Oct 29, 2024
5bb857a
[#20241028] UI: Brand settings with prominent Link Preview
delano Oct 29, 2024
83528c9
[#20241028] UI: Brand settings with new CycleButton component
delano Oct 29, 2024
82f41c8
[#20241028] Updates brand settings with instruction fields
delano Oct 29, 2024
5b3ceef
[#20241028] Enhance SecretPreview component
delano Oct 29, 2024
6af7711
[#20241028] Add instruction field to brand form
delano Oct 29, 2024
7e359bc
[#20241028] Update brand page with header and loading state
delano Oct 29, 2024
472cbac
[#20241028] Add help, tooltips, and a11y features
delano Oct 29, 2024
39744da
[#20241028] 23:45
delano Oct 29, 2024
087af54
[#20241028] 00:16
delano Oct 29, 2024
f4f5065
[#20241028] Adds browser-like preview frame for secrets
delano Oct 29, 2024
3f99b41
[#20241028] Adds functional "View Secret" button in preview
delano Oct 29, 2024
786256b
[#20241028] Add with_brand param to domains list endpoint
delano Oct 29, 2024
74bd199
[#20241028] Fixes route import syntax for lazy loading
delano Oct 29, 2024
97ca7e8
[#20241028] Update StatusBar to use centralized notifications
delano Oct 29, 2024
6237390
[#20241028] Migrate from StatusBar to notifications store
delano Oct 29, 2024
c015cfc
[#20241028] Formatting
delano Oct 29, 2024
365a7bd
[#20241028] Moved original CycleButton with text labels
delano Oct 29, 2024
d118f6d
[#20241028] POST -> PUT for updating brand settings
delano Oct 29, 2024
48587e2
[#20241028] Rename button style to corner style
delano Oct 29, 2024
05502da
[#20241028] Update brand settings UI with icon-based controls
delano Oct 29, 2024
6be6b5e
[#20241028] Fixes button text contrast calculation
delano Oct 29, 2024
fe97872
[#20241028] Fix for preview logo
delano Oct 29, 2024
f5541b2
[#20241028] Relocate instructions to dropdown in settings bar
delano Oct 29, 2024
66613f3
[#20241028] Decompose AccountDomainBrand
delano Oct 29, 2024
13dcc0a
[#20241028] Improve error handling and domain existence check
delano Oct 29, 2024
0b67ae2
[#20241028] Update brand settings list for custom domain
delano Oct 29, 2024
de52ce8
[#20241028] Enhance brand settings update logic and improve Instructi…
delano Oct 29, 2024
b25d54b
[#20241028] Update brand settings UI with consistent styling
delano Oct 29, 2024
63c911a
[#20241028] Formatting, organizing css classes
delano Oct 29, 2024
b8d11ec
[#20241028] Add Microsoft Edge preview w/ toggle
delano Oct 29, 2024
a9386d3
[#20241028] Add interactive toggle to browser preview
delano Oct 29, 2024
565e1b1
[#20241028] Empower status bar to appear on bottom or top
delano Oct 29, 2024
30ade71
[#20241028] Add preview section header and enhance UX elements
delano Oct 29, 2024
5b86d17
[#20241028] Add route prefetching for domain branding
delano Oct 29, 2024
e4e2044
[#20241028] Add informative text to BrowserPreviewFrame
delano Oct 29, 2024
3862b7d
[#20241028] Add VerificationInfo status badge
delano Oct 29, 2024
a74cf1c
[#20241028] Add navigation guards for unsaved brand settings
delano Oct 29, 2024
cbde7a8
[#20241028] Instructions modal refinements
delano Oct 29, 2024
fcad609
[#20241028] Fix for onetime types path
delano Oct 29, 2024
c4968ba
[#20241028] Brand settin gs screen text
delano Oct 30, 2024
423a9db
[#20241028] Improves domain header responsiveness
delano Oct 30, 2024
0683527
[#20241028] Improve mobile responsiveness
delano Oct 30, 2024
c0f1442
[#20241028] Review domains table UI and accessibility
delano Oct 30, 2024
b0bb57b
[#20241028] Update SettingsModal a11y and responsiveness
delano Oct 30, 2024
ed88bf5
[#20241028] UI: domains table Add button and list color
delano Oct 30, 2024
3e5b94a
[#20241028] Update SettingsModal a11y cont'd, jurisdiction tab
delano Oct 30, 2024
5ce948e
[#20241028] Add FocusTrap component
delano Oct 30, 2024
b05471c
[#20241028] A11y review (not comprehensive)
delano Oct 30, 2024
3ddca81
[#20241028] Update auth route tests
delano Oct 30, 2024
c88fb46
[#20241028] Set max filesize to 1MB
delano Oct 30, 2024
de2597c
[#20241028] Remove unused form
delano Oct 30, 2024
c1dda74
[#817] Updated local build assets
delano Oct 30, 2024
366c562
Merge pull request #819 from onetimesecret/817-refresh-built-files
delano Oct 30, 2024
8a33b93
[#817] Refines installation and setup documentation
delano Oct 31, 2024
02e802c
Merge pull request #821 from onetimesecret/817-readme-polish
delano Oct 31, 2024
a1861c6
[#817] Update README manual installation
delano Oct 31, 2024
a1b1756
[#817] Improve manual setup docs
delano Oct 31, 2024
532c3da
[#817] Set default external encoding to UTF-8
delano Oct 31, 2024
3f2ed1a
Merge pull request #822 from onetimesecret/817-manual-installation-re…
delano Oct 31, 2024
98b4bac
[#766] Add horreum refinements
delano Nov 1, 2024
9520ee8
[#766] .
delano Nov 2, 2024
44f5058
[#766] Move model db selection to config
delano Nov 2, 2024
8ac3f5c
[#766] Updates Redis connection with model-specific DB config
delano Nov 2, 2024
427060c
[#766] Updates Redis DB access to use connection hash
delano Nov 2, 2024
18aae62
[#823] Updates initialization and validation flow
delano Nov 2, 2024
60b99f6
[#823] Improve custom domain verification, error handling
delano Nov 2, 2024
f53667c
[#823] Add comprehensive custom domain verification tests
delano Nov 2, 2024
23934c4
[#823] Refines custom domain verification states and display
delano Nov 2, 2024
a3ef3bd
[#823] Moves TXT record generation to domain verification
delano Nov 2, 2024
cc24960
[#823] Add customer management and domain validation CLI tools
delano Nov 3, 2024
57592c8
[#823] Logs unverified custom domains instead of skipping
delano Nov 3, 2024
57a5b2a
[#823] Adds Customer instance validation with fallback
delano Nov 3, 2024
850e3fc
Merge pull request #824 from onetimesecret/766-dockerredis-wrong-db-i…
delano Nov 3, 2024
a245150
[#820] Remove Onetime::Entropy
delano Nov 3, 2024
13eaa0b
Merge pull request #827 from onetimesecret/820-remove-deprecated-entr…
delano Nov 3, 2024
2ead1ca
[#826] Upgrade Feedback module to proper model class
delano Nov 3, 2024
d01b232
Merge pull request #828 from onetimesecret/826-upgrade-feedback-modul…
delano Nov 3, 2024
89ac875
[#829] Expanded tryouts and RateLimit implementation
delano Nov 3, 2024
566d959
[#829] Enhances rate limiter with docs and improved time handling
delano Nov 3, 2024
e025c61
[#829] Move RateLimit to models
delano Nov 3, 2024
7084ffa
[#829] Refactors RateLimit to use Familia::Horreum
delano Nov 3, 2024
c4cb684
Merge pull request #825 from onetimesecret/823-review-customdomain
delano Nov 3, 2024
cb25822
Merge pull request #830 from onetimesecret/829-upgrade-ratelimit-to-f…
delano Nov 3, 2024
3e00a37
Bump sorbet from 0.5.11608 to 0.5.11633
dependabot[bot] Nov 4, 2024
28c4f32
Bump sorbet-runtime from 0.5.11608 to 0.5.11633
dependabot[bot] Nov 4, 2024
aa75837
Merge pull request #818 from onetimesecret/delano/20241028-logo-alt
delano Nov 7, 2024
b7e6c5d
Merge pull request #814 from onetimesecret/dependabot/bundler/bundler…
delano Nov 7, 2024
0c42525
Merge pull request #834 from onetimesecret/dependabot/bundler/sorbet-…
delano Nov 7, 2024
f3b8f02
Merge pull request #831 from onetimesecret/dependabot/bundler/sorbet-…
delano Nov 7, 2024
0cfa4f2
Bump sorbet from 0.5.11633 to 0.5.11641
dependabot[bot] Nov 7, 2024
6d4bc82
Merge pull request #842 from onetimesecret/dependabot/bundler/sorbet-…
delano Nov 7, 2024
9c07291
Merge pull request #812 from onetimesecret/dependabot/npm_and_yarn/pl…
delano Nov 7, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ GEM
redis-client (0.22.2)
connection_pool
regexp_parser (2.9.2)
rexml (3.3.8)
rexml (3.3.9)
rubocop (1.66.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
Expand All @@ -121,15 +121,15 @@ GEM
bigdecimal
concurrent-ruby (~> 1.0, >= 1.0.2)
simpleidn (0.2.3)
sorbet (0.5.11608)
sorbet-static (= 0.5.11608)
sorbet-runtime (0.5.11608)
sorbet-static (0.5.11608-aarch64-linux)
sorbet-static (0.5.11608-universal-darwin)
sorbet-static (0.5.11608-x86_64-linux)
sorbet-static-and-runtime (0.5.11608)
sorbet (= 0.5.11608)
sorbet-runtime (= 0.5.11608)
sorbet (0.5.11641)
sorbet-static (= 0.5.11641)
sorbet-runtime (0.5.11641)
sorbet-static (0.5.11641-aarch64-linux)
sorbet-static (0.5.11641-universal-darwin)
sorbet-static (0.5.11641-x86_64-linux)
sorbet-static-and-runtime (0.5.11641)
sorbet (= 0.5.11641)
sorbet-runtime (= 0.5.11641)
spoom (1.5.0)
erubi (>= 1.10.0)
prism (>= 0.28.0)
Expand Down
172 changes: 93 additions & 79 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,148 +167,162 @@ Regardless of how you obtained or built the image, follow these steps to run One

OnetimeSecret should now be running and accessible at `http://localhost:3000`.


Ah yes, the classic sudo paradox! Here's my attempt to handle this clearly:


### Manual Installation

If you prefer to work with the source code directly, you can install OnetimeSecret manually. Follow these steps:
This guide covers installing OnetimeSecret manually, whether you're working with an existing development environment or starting from a fresh system.

#### 1. Get the Code
#### Prerequisites

Choose one of these methods:
Required components:
- [Redis Server](https://redis.io/download) (version 5 or higher)
- [Ruby](https://www.ruby-lang.org/en/downloads/) (version 3.1 or higher)
- [Bundler](https://bundler.io/) (version 2.5.x)
- [Node.js](https://nodejs.org/en/download/) (version 20 or higher)
- [pnpm](https://pnpm.io/installation) (version 9.2 or higher)
- Essential build tools and development libraries

* Download the [latest release](https://github.com/onetimesecret/onetimesecret/archive/refs/tags/latest.tar.gz)
* Clone the repository:
#### Installation Steps

```bash
git clone https://github.com/onetimesecret/onetimesecret.git
```
##### 1. Prepare Your Environment

First, verify if you have the required dependencies:

#### 2. Install System Dependencies
```bash
ruby --version # Should be 3.1+
bundler --version # Should be 2.5.x
node --version # Should be 20+
pnpm --version # Should be 9.2+
redis-server -v # Should be 5+
```

Follow these general steps to install the required system dependencies:
For a fresh system installation, follow these steps:

1. Install [Redis Server 5+](https://redis.io/download)
2. Install [Ruby 3.1+](https://www.ruby-lang.org/en/downloads/) and [bundler 2.5*](https://bundler.io/)
3. Install [Node.js 20+](https://nodejs.org/en/download/) and [pnpm 9.2+](https://pnpm.io/installation)
4. Install additional required packages: build-essential, libyaml-dev, libffi-dev
> [!Important]
> If starting with a minimal system (like a fresh Debian container), install `sudo` first:
>
> ```bash
> # Only if starting as root on a minimal system
> apt update && apt install -y sudo
> ```

For Debian/Ubuntu systems, you can use the following commands:
Install system dependencies:

```bash
# Update package list and install basic dependencies
# For Debian/Ubuntu systems:
sudo apt update
sudo apt install -y git redis-server build-essential libyaml-dev libffi-dev

# Install Ruby 3.1
sudo apt install -y ruby3.1 ruby3.1-dev
sudo apt install -y git curl build-essential libyaml-dev libffi-dev redis-server ruby3.1 ruby3.1-dev

# Install Node.js and pnpm
# Install package managers
sudo gem install bundler
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -
sudo apt install -y nodejs
sudo npm install -g pnpm@latest
```

Note: After installation, make sure Redis is running with `service redis-server status`. Start it if needed with `service redis-server start`.
# Start Redis server
sudo service redis-server start
```

For other operating systems, please refer to the official documentation for each dependency to install the correct versions.
> **Note:** If you see audit-related errors when installing pnpm with sudo, this is normal in containers or minimal systems where audit capabilities are limited.

#### 3. Initialize the config files
##### 2. Get the Source Code

```bash
git clone https://github.com/onetimesecret/onetimesecret.git
cd onetimesecret
git rev-parse --short HEAD > .commit_hash.txt
cp --preserve --no-clobber ./etc/config.example.yaml ./etc/config.yaml
```

#### 4. Install Ruby Dependencies
##### 3. Install Dependencies

```bash
sudo gem install bundler
bundle config set --local without 'development test'
bundle update --bundler
# Install Ruby dependencies
bundle install
```

#### 5. Install JavaScript Dependencies

```bash
pnpm install --frozen-lockfile
# Install Node.js dependencies
pnpm install
```

#### 6. Build the Frontend
##### 4. Initialize Configuration

```bash
pnpm run build
git rev-parse --short HEAD > .commit_hash.txt
cp -p ./etc/config.example.yaml ./etc/config.yaml
```

##### 5. Choose Your Running Mode

#### 7. Run the Web Application
You can run the application in two ways:

There are two main ways to run the application, depending on your development needs:
###### Option A: Standard Mode (Static Frontend, Choose RACK_ENV)

##### Option A: Without Vite Dev Server (Production-like or Simple Development)
Best for production or development without frontend changes:

1. For production or simple development without frontend changes:
1. Build frontend assets (optional, pre-built assets included):

```bash
RACK_ENV=production bundle exec thin -R config.ru -p 3000 start
```
```bash
pnpm run build:local
```

Or, for a development environment with a static frontend and Ruby live reloading:
2. Set development mode to false in `etc/config.yaml`:

```bash
RACK_ENV=development bundle exec thin -R config.ru -p 3000 start
```
```yaml
:development:
:enabled: false
```

Ensure `development.enabled` is set to `false` in `etc/config.yaml`:
3. Start the server (choose environment as needed):

```yaml
:development:
:enabled: false
```
```bash
# For production
RACK_ENV=production bundle exec thin -R config.ru -p 3000 start

This uses pre-built frontend assets in the `dist/assets` directory.
# Or for backend development
RACK_ENV=development bundle exec thin -R config.ru -p 3000 start
```

##### Option B: With Vite Dev Server (Active Frontend Development)
###### Option B: Frontend Development Mode

1. Set `development.enabled` to `true` in `etc/config.yaml`:
Best for active frontend development with live reloading:

1. Enable development mode in `etc/config.yaml`:
```yaml
:development:
:enabled: true
```

2. Run the Thin server in development mode:

2. Start the main server:
```bash
RACK_ENV=development bundle exec thin -R config.ru -p 3000 start
```

3. In a separate terminal, start the Vite dev server:

3. Start the Vite dev server (in a separate terminal):
```bash
pnpm run dev
```

This enables live reloading of frontend assets.
#### Technical Details for Frontend Development

The application determines whether to use development or production assets based on the `development.enabled` setting. In development mode with the Vite server running, frontend assets are loaded dynamically:
When running in development mode (Option B), the application uses Vite's dev server for dynamic asset loading and hot module replacement. Here's how it works:

```html
{{#frontend_development}}
<script type="module" src="{{ frontend_host }}/dist/main.ts"></script>
<script type="module" src="{{ frontend_host }}/dist/@vite/client"></script>
{{/frontend_development}}
```

In production mode, it uses the built files in `dist/assets`:
- In development mode (`development.enabled: true`), the application loads assets dynamically from the Vite dev server:
```html
{{#frontend_development}}
<script type="module" src="{{ frontend_host }}/dist/main.ts"></script>
<script type="module" src="{{ frontend_host }}/dist/@vite/client"></script>
{{/frontend_development}}
```

```html
{{^frontend_development}}
{{{vite_assets}}}
{{/frontend_development}}
```
- In production mode (`development.enabled: false`), it uses pre-built static assets:
```html
{{^frontend_development}}
{{{vite_assets}}}
{{/frontend_development}}
```

Choose the option that best fits your development workflow and needs.
This setup enables features like hot module replacement and instant updates during frontend development, while ensuring optimal performance in production.

## Configuration

Expand All @@ -319,7 +333,7 @@ OnetimeSecret requires a `config.yaml` file for all installations. Environment v
1. Create the configuration file:

```bash
cp --preserve --no-clobber ./etc/config.example.yaml ./etc/config.yaml
cp -p ./etc/config.example.yaml ./etc/config.yaml
```

2. Review and edit `./etc/config.yaml` as needed. At minimum, update the secret key and back it up securely.
Expand Down Expand Up @@ -370,7 +384,7 @@ For various deployment scenarios, including Docker setups and local development,
1. Create the .env file:

```bash
cp --preserve --no-clobber .env.example .env
cp -p .env.example .env
```

2. Edit the `.env` file with your desired configuration.
Expand Down
16 changes: 16 additions & 0 deletions bin/ots
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ require 'drydock'
class OT::CLI::Definition
extend Drydock

before do
puts "" # separate our content from the bootstrapping banner
end

global :v, :verbose, 'Increase output' do
@verbose ||= 0
@verbose += 1
Expand All @@ -41,7 +45,19 @@ class OT::CLI::Definition
command move_keys: OT::CLI

usage 'ots customers'
option :l, :list, "List customer domains (by count)"
option :c, :check, "Show customer records where custid and email do not match (obscured)"
command customers: OT::CLI

usage 'ots domains'
option :l, :list, "List domains"
command domains: OT::CLI

usage 'ots revalidate-domains'
about 'Revalidate domain verification status. Optionally specify a domain and/or customer_id.'
option :d, :domain, String, "Domain to revalidate"
option :c, :custid, String, "Customer ID to revalidate"
command revalidate_domains: OT::CLI
end

begin
Expand Down
9 changes: 9 additions & 0 deletions config.ru
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ end
# Load Paths
$LOAD_PATH.unshift(File.join(app_root, 'lib'))

# Freshly installed operating systems don't always have their locale settings
# figured out. By setting this to UTF-8, we ensure that:
# - All file I/O operations default to UTF-8 encoding.
# - Network I/O operations treat data as UTF-8 encoded.
# - Standard input/output (STDIN, STDOUT, STDERR) uses UTF-8 encoding.
# - Strings created from external sources default to UTF-8 encoding.
# This helps maintain consistency and reduces encoding-related issues.
Encoding.default_external = Encoding::UTF_8

# Required Libraries
require 'rack/content_length'
require 'rack/contrib'
Expand Down
23 changes: 22 additions & 1 deletion etc/config.example.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
---
:site:
:host: <%= ENV['HOST'] || 'localhost:3000' %>
:domains:
Expand Down Expand Up @@ -62,8 +61,30 @@
# These options will be presented to users when they create a new secret
# Format: String of integers representing seconds
:ttl_options: <%= (ENV['TTL_OPTIONS'] || nil) %>
# Redis Configuration
:redis:
# Main Redis connection URI - Specify full connection string including auth
# Format: redis://[:password@]host[:port]/[db-number]
# Examples:
# - redis://mypassword@localhost:6379/0 # Simple password auth
# - redis://user:pass@localhost:6379/0 # Username/password auth
# - redis://redis.example.com:6379/0 # No auth (development only)
:uri: <%= ENV['REDIS_URL'] || 'redis://[email protected]:6379/0' %>
# Database Mapping Configuration
# These mappings allow separating data across different Redis logical
# databases (0-15). These can be arranged any way you like.
# Note: If using a Redis provider with single-database limitation (e.g., Upstash),
# set all values to 0.
:dbs:
:session: 1
:splittest: 1
:custom_domain: 6
:customer: 6
:subdomain: 6
:metadata: 7
:email_receipt: 8
:secret: 8
:feedback: 11
:colonels:
# Email addresses listed below will be granted automatic
# administrative privileges upon account creation. These
Expand Down
Loading
Loading