OliveTin is a web interface for running Linux shell commands.

OliveTin

project logo

OliveTin is a web interface for running Linux shell commands.

Discord Go Report Card

Some example use cases;

  1. Give controlled access to run shell commands to less technical folks who cannot be trusted with SSH. I use this so my family can podman restart plex without asking me, and without giving them shell access!
  2. Great for home automation tablets stuck on walls around your house - I use this to turn Hue lights on and off for example.
  3. Sometimes SSH access isn't possible to a server, or you are feeling too lazy to type a long command you run regularly! I use this to send Wake on Lan commands to servers around my house.

Join the community on Discord.

YouTube video demo (6 mins)

6 minute demo video

Features

  • Responsive, touch-friendly UI - great for tablets and mobile
  • Super simple config in YAML - because if it's not YAML now-a-days, it's not "cloud native" :-)
  • Dark mode - for those of you that roll that way.
  • Accessible - passes all the accessibility checks in Firefox, and issues with accessibility are taken seriously.
  • Container - available for quickly testing and getting it up and running, great for the selfhosted community.
  • Integrate with anything - OliveTin just runs Linux shell commands, so theoretially you could integrate with a bunch of stuff just by using curl, ping, etc. However, writing your own shell scripts is a great way to extend OliveTin.
  • Lightweight on resources - uses only a few MB of RAM and barely any CPU. Written in Go, with a web interface written as a modern, responsive, Single Page App that uses the REST/gRPC API.
  • Good amount of unit tests and style checks - helps potential contributors be consistent, and helps with maintainability.

Screenshots

Desktop web browser;

Desktop screenshot

Desktop web browser (dark mode);

Desktop screenshot

Mobile screen size (responsive layout);

Mobile screenshot

Documentation

All documentation can be found at http://olivetin.app . This includes installation and usage guide, etc.

Example config.yaml

Put this config.yaml in /etc/OliveTin/ if you're running a standard service, or mount it at /config if running in a container.

listenAddressWebUI: 0.0.0.0:1337 # Listen on all addresses available, port 1337
logLevel: "INFO"
actions: 
- title: Restart Plex
  icon: smile
  shell: docker restart plex
  
  # This will send 1 ping 
- title: Ping Google.com
  shell: ping google.com -c 1
  
  # Restart lightdm on host "overseer"
- title: restart lightdm
  icon: poop
  shell: ssh root@overseer 'service lightdm restart'

A full example config can be found at in this repository - config.yaml.

Owner
OliveTin
OliveTin is a simple web interface for running Linux shell commands.
OliveTin
Comments
  • [BUG] Error getting initial buttons

    [BUG] Error getting initial buttons

    Describe the bug Error getting initial buttons is displayed when opening the web ui. TypeError: NetworkError when attempting to fetch resource.

    To Reproduce Build with docker-compose

    version: "2.1"
    services:
      airsonic:
        image: jamesread/olivetin
        container_name: olivetin
        restart: unless-stopped
        environment:
          - PUID=1000
          - PGID=1000
          - TZ=America/
        volumes:
          - /olivetin:/config
        labels:
          - "traefik.enable=true"
          - "traefik.http.routers.olivetin.rule=Host(`olivetin.example.com`)"
          - "traefik.http.routers.olivetin.entrypoints=websecure"
          - "traefik.http.routers.olivetin.tls=true"
          # Uncomment to fetch Let's Encrypt certificates.
          # Make sure you set up DNS records and they point to your IP.
          - "traefik.http.routers.olivetin.tls.certresolver=letsencrypt"
    
    networks:
      default:
        external:
          name: traefik_default
    
    
    
    

    Expected behavior Page should launch with 1 button as per the config.yaml

    Screenshots image

  • ARM binaries not working on older Pi Zero W

    ARM binaries not working on older Pi Zero W

    Trying to run the current OliveTin_2021-11-19_linux_armv7.deb on an older Pi Zero W with Debian Stretch doesn't work and just returns an "Illegal instruction" message. The last releases which worked where the older armv6 packages.

    So I went ahead and built from source which does produce a working binary. What I do miss is a make target or something to turn this into a .deb package, though?

    Also, manually copying the new OliveTin binary over an old installation lets me start the server, but then returns a "TypeError: json.actions is undefined" on the web UI. This runs with an existing config.yaml, but I don't see any breaking changes there which would explain that message.

  • `dnf install` should be run as supeuser inside container

    `dnf install` should be run as supeuser inside container

    Describe the bug When trying to install docker inside olivetin it is not possible due to lack of superuser permissions.

    To Reproduce

    1. Install olivetin using dockerfile
    2. Perform additional steps for docker. (Tweaked the dockerfile instead)
    3. run docker exec -it olivetin dnf install -y docker Error: This command has to be run with superuser privileges (under the root user on most systems). or
    4. run docker exec -it olivetin sudo dnf install -y docker [sudo] password for olivetin:

    Expected behavior Should install docker

    Additional context

    dockerfile
    ---
    version: "2.1"
    services:
      olivetin:
        container_name: olivetin
        image: jamesread/olivetin 
    
        volumes:
          - /srv/dev-disk-by-uuid-d2287285-5827-439a-bc32-7c8ad314eacf/Config/OliveTin:/config:ro
          - /var/run/docker.sock:/var/run/docker.sock
        ports:
          - "1337:1337"
        restart: unless-stopped
    

    Running inside Portainer 2.6.1 on Openmediavault 5.6.7-1

    $ uname -a
    Linux rockpi 5.10.35-rockchip64 #21.05.1 SMP PREEMPT Fri May 7 13:53:11 UTC 2021 aarch64 GNU/Linux
    

    Suggestion: If you don't want to run the container as root, what about adding something like olivetin ALL=(ALL) /usr/bin/dnf in /etc/sudoers?

  • Disable the

    Disable the "Actions" and "Logs" buttons

    Is your feature request related to a problem? Please describe. For non tech. people to provide as few buttons as possible.

    Describe the solution you'd like It would be nice to disable the "Actions" and "Logs" buttons on the top of the page to make it as clean as possible. In config.yaml something like navigation: disable.

    Additional context I equipped my parents in law with a raspberry running kodi. Every now and then kodi hangs and the only option for them on their own is to power cycle the pi. The more elegant solution would be to just restart the service, for which I haven't found an elegant solution for non technical people until I stumbled upon OliveTin. This will be a website-link on their phones open the site with only one button "Restart Kodi".

  • Arm64 / armv7 docker image?

    Arm64 / armv7 docker image?

    Hi, your project looks really promising and would be very useful for lots of people running SBCs as servers. However at the moment there is no docker image for these platforms. If you could create one that would be awesome!

  • Task arguments

    Task arguments

    It would be nice to trigger a task with a arguments, such a light brightness, custom timeouts, or similar.

    Describe the solution you'd like Available to be set on a per action basis, the ability to specify a couple of arguments.

    There are considerable security implications of doing this though - you're basically giving free SSH access to a server if the arguments are abused.

    Additional context Originally requested by Luca Heitmann here; https://youtu.be/Ej6NM9rmZtk

    Current status

    • [x] Get the UI to send these values back to the server when starting the action
    • [x] Find/Replace variable names (ie, actually use them) on exec
    • [x] Fix behavior for undefined variables, unused variables, etc
    • [x] A type system for variables, with several safe/unsafe helpers (ie string_identifier, string_raw_unsafe)
    • [x] Code audit for style, cyclo, fmt, etc.
    • [ ] Test the hell out of it

    Feedback

    Feedback is most welcome, even if it's just a :+1: on this comment to indicate you're interested in the feature.

  • --config flag

    --config flag

    As per the documentation on how to set up multiple instances, I'd like to suggest the addition of a feature that could make the process even simpler: a flag (tentatively called config, but the name is irrelevant) that allows to specify the location of the config.yaml when this is not in the default directory.

    For example, in order to create a second OliveTin instance, all I'd have to do would be to place a second config.yaml in /home/myuser/OliveTin2, and then call the executable located in /usr/local/bin/OliveTin with this service file:

    [Unit]
    Description=OliveTin2
    
    [Service]
    ExecStart=/usr/local/bin/OliveTin --config /home/myuser/OliveTin2/config.yaml
    Restart=always
    
    [Install]
    WantedBy=multi-user.target
    

    This differs from the method in the documentation in that it doesn't need to use a different copy of the executable for each instance, as it can use one executable for all instances; including the one installed in the default location by the .deb/.rpm installer.

    It'd also allow to give the config.yaml any name, which would make possible to have multiple configuration files in the same directory (for example, I could have /home/myuser/OliveTin_configs with files called config2.yaml, config3.yaml, etc.).

    And even though it's possible to do something similar simply by specifying a WorkingDirectory in the service file, this is a more cross-OS method. For example, if I was using Windows, I could make a shortcut that called the executable this way:

    C:\Program Files\OliveTin\OliveTin.exe --config C:\Users\MyUser\OliveTin2\config.yaml

    Or it could be used for distros that don't use systemd, or if for some reason I can't or don't want to use a service file; for example, if I'm running it on a machine where I don't have root permissions (the latter could be paired with a webUIDirectory option in the config.yaml that similarly allows to choose a different location for the web files, but that's independent from this suggestion).

  • Apple touch icon support

    Apple touch icon support

    Is your feature request related to a problem? Please describe.

    Apple devices rely on a separate metadata description for "touch icons".

    https://lynk.icu/F79pi

    Originally requested by ScrumpyJack on discord.

  • Standard naming convention for releases

    Standard naming convention for releases

    Is your feature request related to a problem? Please describe. Don't include version name in releases. Tag based release identifiers make it easy to curl latest package in a script

    Describe the solution you'd like Rather than release named OliveTin_2022-04-07_linux_amd64.deb, it should be OliveTin_linux_amd64.deb

    Additional context Follow a standard naming convention for release names since tags serve as release number. For practical representation, refer to Adguard Home's release page

  • Document HTTP API for use with 3rd party apps

    Document HTTP API for use with 3rd party apps

    Cool app. Excited to see where it goes.

    My request is to document the API so other users can easily integrate with 3rd party apps, For example, I'm using it in combination with HTTP Request Shortcuts so I can place OliveTin actions right on my homescreen.

    Current API seems simple enough. Actions can be triggered by POSTing to http://<HOST>/api/StartAction with the following request

    {"actionName":"Start transmission-daemon","arguments":[]}
    
  • user interaction with the script

    user interaction with the script

    Interaction with the bash script All is good with 'fire and forget' actions with no parameter. There are other very interesting scenarios which require some form of interaction. Can we use OliveTin in those cases?

    My OliveTin is OliveTin_2021-07-19_linux_amd64.deb, running in ubuntu 20.04 My script is of the type 'sudo bashcommand', how do I send the user's password? The action complete without errors but the log show nothing. Can I find docs for this type of script?

    More generally, how do I allow a script to accept user input and continue processing? I have scripts which require input from user in the middle of processing: can I interact with the script in some way?

    Thank you for your help

  • build(deps): bump json5 from 1.0.1 to 1.0.2 in /webui

    build(deps): bump json5 from 1.0.1 to 1.0.2 in /webui

    Bumps json5 from 1.0.1 to 1.0.2.

    Release notes

    Sourced from json5's releases.

    v1.0.2

    • Fix: Properties with the name __proto__ are added to objects and arrays. (#199) This also fixes a prototype pollution vulnerability reported by Jonathan Gregson! (#295). This has been backported to v1. (#298)
    Changelog

    Sourced from json5's changelog.

    Unreleased [code, diff]

    v2.2.3 [code, diff]

    v2.2.2 [code, diff]

    • Fix: Properties with the name __proto__ are added to objects and arrays. (#199) This also fixes a prototype pollution vulnerability reported by Jonathan Gregson! (#295).

    v2.2.1 [code, diff]

    • Fix: Removed dependence on minimist to patch CVE-2021-44906. (#266)

    v2.2.0 [code, diff]

    • New: Accurate and documented TypeScript declarations are now included. There is no need to install @types/json5. (#236, #244)

    v2.1.3 [code, diff]

    • Fix: An out of memory bug when parsing numbers has been fixed. (#228, #229)

    v2.1.2 [code, diff]

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • OliveTin phones home to developers with PII without consent

    OliveTin phones home to developers with PII without consent

    https://github.com/OliveTin/OliveTin/blob/244404afbc2fcd854476997370cde923ee54e207/internal/config/config.go#L93

    The "update check" is enabled by default. This misleadingly named surveillance feature will phone home to the developers of the software at http://update-check.olivetin.app:

    https://github.com/OliveTin/OliveTin/blob/49cb2e5c0a5e64abe45b87f2470ef2605e5b2596/internal/updatecheck/updateCheck.go#L109

    It's not just checking for updates. It sends to the server personally identifying information (PII), something called an "installation ID", which persists between launches:

    https://github.com/OliveTin/OliveTin/blob/49cb2e5c0a5e64abe45b87f2470ef2605e5b2596/internal/updatecheck/updateCheck.go#L32

    This network-based surveillance is not disclosed to the user and happens without first obtaining consent from the user. The user's PII is transmitted automatically.

  • Feature request: run scripts at startup

    Feature request: run scripts at startup

    Is your feature request related to a problem? Please describe. OliveTin doesn't always include the executables I'd like to run.

    Describe the solution you'd like I'd really like the ability to automatically run scripts when OliveTin is started, sort of like how the LinuxServer containers have implemented. This would allow me to install executables within the container each time it's rebuilt.

    I used this with another Docker image I used up until recently - I needed some additional stuff installed, so I wrote a small script to install the extras each time the container was rebuilt.

    Describe alternatives you've considered For now, I can do this manually, or script it myself when building the container.

    Additional context #89 made me think of this - instead of having to include docker compose in the image, it'd be really great if I could just install it myself, automatically, each time the container is built. This would keep the image small and free of additional security issues, depending on what users might want to have installed.

    Thanks!

  • Add `docker compose` to docker images by default

    Add `docker compose` to docker images by default

    I really appreciate that docker is pre-installed in the images. It would be even better, if the docker compose plugin was installed as well.

    This would allow simple compose based services to be restarted etc.. i.e. shell: docker compose up -d

    Based on the official docker docs this works:

    mkdir -p /usr/local/lib/docker/cli-plugins
    curl -SL https://github.com/docker/compose/releases/latest/download/docker-compose-linux-x86_64 \
     -o /usr/local/lib/docker/cli-plugins/docker-compose
    chmod +x /usr/local/lib/docker/cli-plugins/docker-compose
    

    This could be added to the RUN "install"command in the Dockerfiles.

  • Switch from

    Switch from "-" in version to standard "." in version.

    This issue will track it.

    • [ ] Check Arch
    • [ ] Check the download script
    • [ ] Check docs pages
    • [ ] Check name of folder in tar.gz and zip
    • [ ] Check release notes template
Retro-Floppy UI is a web based application for managing & using a GoTek floppy emulator running the Flash Floppy firmware.
Retro-Floppy UI is a web based application for managing & using a GoTek floppy emulator running the Flash Floppy firmware.

A web user interface for a GoTek running flashfloppy utilising a Raspberry PI 0W as the storage. This allows for remote uploading of files & selecting which disk image is loaded on a retro computer like the BBC Micro or Amiga A1200

Dec 10, 2022
Web interface for Wireguard. Supports SSO.
Web interface for Wireguard. Supports SSO.

A simple, easy to use web interface for Wireguard. It supports SSO authentication (currently Google, Github, Gitlab, Okta are supported) and SCIM2.0 protocol (in development).

Apr 6, 2022
Gramaddict web UI interface for a single device

Gramaddict web UI interface for a single device allow you to see the logs in real time, start and stop the bot all from your browser.

Dec 20, 2021
An RRDtool api server that exports a subset of rrdtool commands over http(s).

rrdsrv An RRDtool api server that exports a subset of rrdtool commands over http(s). Be sure to checkout the grafana plugin. Demo video. Usage Usage o

Dec 7, 2022
A library to curb OOMs by running Go GC according to a user-defined policy

Go memory watchdog ?? A library to curb OOMs by running Go GC according to a user-defined policy. Package watchdog runs a singleton memory watchdog in

Nov 26, 2021
Extract structured data from web sites. Web sites scraping.
Extract structured data from web sites. Web sites scraping.

Dataflow kit Dataflow kit ("DFK") is a Web Scraping framework for Gophers. It extracts data from web pages, following the specified CSS Selectors. You

Jan 7, 2023
記帳-PWA-web-app (Bookkeeping-PWA-web-app)
記帳-PWA-web-app (Bookkeeping-PWA-web-app)

GoKeep (bookkeeping web app) 記帳-PWA-web-app (Bookkeeping-PWA-web-app) demo link : https://bookkepping.herokuapp.com/ 測試用帳密 : tester002 , tester002 (亦可

Jan 31, 2022
log4jScanner: provides you with the ability to scan internal (only) subnets for vulnerable log4j web servicelog4jScanner: provides you with the ability to scan internal (only) subnets for vulnerable log4j web service
log4jScanner: provides you with the ability to scan internal (only) subnets for vulnerable log4j web servicelog4jScanner: provides you with the ability to scan internal (only) subnets for vulnerable log4j web service

log4jScanner Goals This tool provides you with the ability to scan internal (only) subnets for vulnerable log4j web services. It will attempt to send

Jan 5, 2023
Go-web-scaffold - A simple scaffold for building web app quickly

Go-web-scaffold A simple scaffold for building web app quickly. features This sc

Jan 21, 2022
CRUD REST interface for transmission's RPC. Written in Go.

transmission-rest a CRUD REST interface for transmission's RPC. Written in Go using github.com/hekmon/transmissionrpc/v2 Configuration Empty config fi

Oct 14, 2021
BLM3 Compatible with restful interface

BLM3 Function Compatible with restful interface Compatible with influxdb v1 write interface Compatible with opentsdb json and telnet format writing Se

Dec 11, 2021
IP geolocation web server

freegeoip NOTE: as of April 2018 this repository is no longer active. Please visit https://github.com/apilayer/freegeoip/ for the current version. Thi

Dec 26, 2022
Polite, slim and concurrent web crawler.

gocrawl gocrawl is a polite, slim and concurrent web crawler written in Go. For a simpler yet more flexible web crawler written in a more idiomatic Go

Dec 31, 2022
A quick and easy password protected web server for your files. httpfolder makes downloading/uploading files from your current working directory easy, even for fairly large files.

httpfolder A quick and easy password protected web server for your files. httpfolder makes downloading/uploading files from your current working direc

Sep 12, 2022
sigurlx a web application attack surface mapping tool.

sigurlx a web application attack surface mapping tool, it does ...:

Jul 24, 2021
Minimalist open-source web analytics

Zero-effort web analytics. This is a self-hosted open-source version of Nullitics.

Nov 10, 2022
Generate a modern Web project with Go and Angular, React or Vue in seconds 🚀
Generate a modern Web project with Go and Angular, React or Vue in seconds 🚀

Goxygen Generate a Web project with Go and Angular, React or Vue. Goxygen aims at saving your time while setting up a new project. It creates a skelet

Jan 5, 2023
GoTTY - Share your terminal as a web application
 GoTTY - Share your terminal as a web application

GoTTY - Share your terminal as a web application GoTTY is a simple command line tool that turns your CLI tools into web applications. Installation Fro

Dec 28, 2022
GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework
GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework

GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework, it features a simple organized directory structure for your next project with a pleasant development experience, made for developing modern APIs and microservices.

Dec 29, 2022