Skip to main content

Logo Dawarich

About

Do you remember where you've been last year? With Dawarich, you don't have to worry about forgetting. We help you remember the places you've been and the life you've lived — day by day, on a beautiful private timeline only you control.

Disable registration

To disable registration, edit /app/data/env.sh using the File manager:

Bash
export ALLOW_EMAIL_PASSWORD_REGISTRATION=false

Restart the app for the changes to take effect.

Rails Console

In the Web Terminal, run the following command to access the Rails console:

Bash
#!/bin/bash

# Ensure workdir is set to the application code directory
cd /app/code/

# Database Setup
export DATABASE_HOST="${CLOUDRON_POSTGRESQL_HOST}"
export DATABASE_PORT=${CLOUDRON_POSTGRESQL_PORT}
export DATABASE_USERNAME="${CLOUDRON_POSTGRESQL_USERNAME}"
export DATABASE_PASSWORD="${CLOUDRON_POSTGRESQL_PASSWORD}"
export DATABASE_NAME="${CLOUDRON_POSTGRESQL_DATABASE}"

# Application Setup
export RAILS_ENV="production"
export APPLICATION_HOSTS="${CLOUDRON_APP_DOMAIN}"
export RAILS_LOG_TO_STDOUT="true"
export SECRET_KEY_BASE=$(./bin/rails secret)
export SELF_HOSTED="true"
export STORE_GEODATA="true"
export DOMAIN="${CLOUDRON_APP_DOMAIN}"

# Redis Addon Setup
export REDIS_URL="${CLOUDRON_REDIS_URL}"

# Sendmail Addon Setup
if [[ -n "${CLOUDRON_MAIL_SMTP_SERVER:-}" ]]; then
export SMTP_SERVER="${CLOUDRON_MAIL_SMTP_SERVER}"
export SMTP_PORT="${CLOUDRON_MAIL_SMTP_PORT}"
export SMTP_USERNAME="${CLOUDRON_MAIL_SMTP_USERNAME}"
export SMTP_PASSWORD="${CLOUDRON_MAIL_SMTP_PASSWORD}"
export SMTP_DOMAIN="${CLOUDRON_MAIL_DOMAIN}"
export SMTP_FROM="${CLOUDRON_MAIL_FROM}"
export SMTP_STARTTLS="false"
fi

# OIDC Addon Setup
if [[ -n "${CLOUDRON_OIDC_ISSUER:-}" ]]; then
export OIDC_CLIENT_ID="${CLOUDRON_OIDC_CLIENT_ID}"
export OIDC_CLIENT_SECRET="${CLOUDRON_OIDC_CLIENT_SECRET}"
export OIDC_ISSUER="${CLOUDRON_OIDC_ISSUER}"
export OIDC_REDIRECT_URI="https://${CLOUDRON_APP_DOMAIN}/users/auth/openid_connect/callback"
export OIDC_AUTO_REGISTER=true
export OIDC_PROVIDER_NAME="Cloudron"
fi

source /app/data/env.sh

gosu cloudron:cloudron bundle exec rails console