Skip to content

add flag to disable auth mode#83

Open
Tootam wants to merge 3 commits into
louislam:masterfrom
Tootam:fix/disable-auth-mode
Open

add flag to disable auth mode#83
Tootam wants to merge 3 commits into
louislam:masterfrom
Tootam:fix/disable-auth-mode

Conversation

@Tootam

@Tootam Tootam commented Jun 28, 2026

Copy link
Copy Markdown

fixes #74

ELI5: Optional Login Disable Mode

This branch adds a simple switch for people who run It's MyTabs behind their own login system, like Authentik, Authelia, NGINX auth, Cloudflare Access, or a private VPN.

What changed?

There is now a new environment variable:

MYTABS_DISABLE_AUTH=true

When this is set to true, It's MyTabs does not ask users to log in.

The app assumes that something else in front of it is already protecting access.

Default behavior

By default, auth is still enabled:

MYTABS_DISABLE_AUTH=false

So existing installs keep working the same way as before.

What happens when auth is disabled?

When MYTABS_DISABLE_AUTH=true:

  • the first-start admin account setup is skipped
  • the login page redirects to the app
  • the register page redirects to the app
  • protected API routes are treated as authenticated
  • private tabs are accessible without an app login
  • logout/login buttons are hidden in the UI

Important security note

Only disable auth if the app is protected another way.

Good examples:

  • Authentik in front of NGINX
  • Authelia
  • Cloudflare Access
  • VPN-only access
  • LAN-only private service

Do not expose the app directly to the internet with auth disabled.

Docker usage

In compose.yaml, the default is:

environment:
MYTABS_DISABLE_AUTH: "false"

To disable auth, change it to:

environment:
MYTABS_DISABLE_AUTH: "true"

Then restart the container.

Running without Docker

If you run the app directly with Deno, set the environment variable before starting.

Linux/macOS

MYTABS_DISABLE_AUTH=true deno task start

Or export it first:

export MYTABS_DISABLE_AUTH=true
deno task start

Windows PowerShell

$env:MYTABS_DISABLE_AUTH="true"
deno task start

.env file

You can also add this to your .env file:

MYTABS_DISABLE_AUTH=true

Then start the app normally:

deno task start

Re-enabling built-in auth

Set the variable back to false or remove it:

MYTABS_DISABLE_AUTH=false

If no admin user exists yet, the app will ask you to create one again on startup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Is it possible to disable the login?

1 participant