Skip to content
/ main Public

!3 is a simple, secure and open source paste sharing platform.

License

Notifications You must be signed in to change notification settings

not-three/main

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

95 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

not-th.re

license GNU AGPLv3 gitHub issues

ui releases build ui Nightly ui commits

api releases build api Nightly api commits

sdk releases sdk npm package build sdk Nightly sdk commits

cli releases cli npm package build cli Nightly cli commits

!3 (spoken not three, derived from the leet speak word not3) is a simple paste sharing platform similar to other solutions like hastebin or pastebin.

!3 is focused on simplicity, security by client side encryption and usage of the monaco editor.

Features

  • Simple paste sharing
  • Client side encryption
  • Monaco editor
  • Syntax highlighting
  • Dark mode
  • New: File transfers
  • New: Connect your private instance with the public UI
  • Planned: Excalidraw integration
  • Planned: Peer 2 Peer sessions
  • Planned: Note Bundles
  • Planned: HTML Previewer
  • Planned: JavaScript Console
  • No cookies
  • No tracking
  • No ads

Cli

We also provide a cli tool to interact with the API.

npm install -g @not3/cli
$ not3 --help
Usage: not3 [options] [command]

Options:
  -V, --version                              output the version number
  -h, --help                                 display help for command

Commands:
  license                                    Show information about the license of the software
  decrypt [options] <seed>                   Decrypt something
  encrypt [options] [input...]               Encrypt something, if no input is provided, will read from stdin
  download|d [options] <id> <seed> <output>  Download a file and decrypt it
  upload|u [options] <input>                 Upload a file and encrypt it
  query|q [options] <id> <seed>              Decrypt and show a note from the server
  save|s [options] [content...]              Encrypt and save a note on the server
  seed                                       Generate a new encryption seed
  info [options]                             Show meta information about the api
  stats [options]                            Show usage statistics of the server
  help [command]                             display help for command

Deployment

The simplest way to use !3 is to visit our hosted instance at https://not-th.re.

Micro

The micro deployment does not bring its own UI, but you can use the public UI.

services:
  api:
    image: ghcr.io/not-three/api:latest
    restart: unless-stopped
    environment:
      CORS_ENABLED: true
      LIMITS_DISABLED: true
      INSTANCE_PASSWORD: MySecretPassword
    ports:
      - 4000:4000
    volumes:
      - db:/data/db

volumes:
  db:

After you have deployed the API, visit the public UI go to Tools -> Edit Settings and update these values:

{
  "customServer": {
    "url": "http://<ip-of-the-server>:4000/",
    "password": "MySecretPassword"
  }
}

Dont forget to save the settings, by clicking on File -> Save (or by pressing ctrl + s).

Minimal

The minimal deployment includes both the API and the UI. The UI has the proxy mode enabled, so you only need a single port.

x-restart: &restart
  restart: unless-stopped

services:
  api:
    image: ghcr.io/not-three/api:latest
    <<: *restart
    volumes:
      - db:/data/db

  ui:
    image: ghcr.io/not-three/ui:latest
    <<: *restart
    ports:
      - 4000:4000
    depends_on:
      - api
    environment:
      PROXY_URL: http://api:3000

volumes:
  db:

Simple

An simple deployment, including a postgres database instead of sqlite. Recommended if you want to store more than a few pastes.

x-restart: &restart
  restart: unless-stopped

services:
  api:
    image: ghcr.io/not-three/api:latest
    <<: *restart
    depends_on:
      - db
    ports:
      - 3000:3000
    environment:
      CORS_ENABLED: true
      CORS_ORIGIN: http://localhost:4000
      DATABASE_MODE: pg
      DATABASE_HOST: db
      DATABASE_USERNAME: db
      DATABASE_PASSWORD: db
      DATABASE_NAME: db

  ui:
    image: ghcr.io/not-three/ui:latest
    <<: *restart
    ports:
      - 4000:4000
    environment:
      API_URL: http://localhost:3000
      TERMS_OF_SERVICE_URL: https://example.com

  db:
    image: postgres:14.5
    <<: *restart
    environment:
      POSTGRES_PASSWORD: db
      POSTGRES_USER: db
      POSTGRES_DB: db
    volumes:
      - db:/var/lib/postgresql/data

volumes:
  db:

Advanced

See one of the following files for a more detailed example:

These include horizontal scaling, health checks and traefik as a reverse proxy.

Environment variables

For a full list, with detailed descriptions of all environment variables, see the configuration documentation.

Helm

As of now, we do not have an official helm chart, if you want to contribute one, feel free to open a PR.

Static site deployment

In some scenarios, you might want to deploy the static site without a backend, for example not-th.re is deployed with Cloudflare Pages, while the API is hosted on api.not-th.re.

The static site can then be configured by editing the config.json file.

{ "baseURL": "https://api.not-th.re/", "termsURL": "https://scolasti.co/go/privacy" }

You can download the client bundle from one of the following sources:

Github Releases

All stable versions of the client are available as a github release artifact.

download stable gh releases artifacts

Docker

docker run --rm --entrypoint /bin/sh -v $(pwd):/mnt ghcr.io/not-three/ui:latest -c "cp -r /app/public/ /mnt/public/"

This will copy the public folder to your current working directory.

Github Actions

The nightly (unstable) versions of the client are also available as a github action artifacts.

download nightly gh actions artifacts

License

This project is licensed under the GNU Affero General Public License v3.0.

About

GNU AGPLv3

Permissions of this strongest copyleft license are conditioned on making available complete source code of licensed works and modifications, which include larger works using a licensed work, under the same license. Copyright and license notices must be preserved. Contributors provide an express grant of patent rights. When a modified version is used to provide a service over a network, the complete source code of the modified version must be made available.

What you can do

Permissions Conditions Limitations
🟒 Commercial useThe licensed material and derivatives may be used for commercial purposes.
πŸ”΅ Disclose sourceSource code must be made available when the licensed material is distributed.
πŸ”΄ LiabilityThis license includes a limitation of liability.
🟒 DistributionThe licensed material may be distributed.
πŸ”΅ License and copyright noticeA copy of the license and copyright notice must be included with the licensed material.
πŸ”΄ WarrantyThis license explicitly states that it does NOT provide any warranty.
🟒 ModificationThe licensed material may be modified.
πŸ”΅ Network use is distributionUsers who interact with the licensed material via network are given the right to receive a copy of the source code.
🟒 Patent useThis license provides an express grant of patent rights from contributors.
πŸ”΅ Same licenseModifications must be released under the same license when distributing the licensed material. In some cases a similar or related license may be used.
🟒 Private useThe licensed material may be used and modified in private.
πŸ”΅ State changesChanges made to the licensed material must be documented.

Information provided by https://choosealicense.com/licenses/agpl-3.0/

This information is provided for general understanding and is not legal advice.