CraftTalk Command Line Tool helps with managing CraftTalk releases on baremetal instances

ctcli - CraftTalk Command Line Tool

Commands

help

Shows help

version

Shows version

init

Initializes specified root directory as a ctcli dir.

ctcli --root /path/to/dir init

install

Installs a package into specified root folder. Example:

ctcli install /path/to/package.tar.gz

First it creates tmp dir and extracts an archive. Then it creates oci image config and rootfs folder. Then it copies unpacked images to current-release folder. Makes symlinks for logs folder and configs. Creates a zero backup.

upgrade

Upgrades a release with binaries contained in given package. Backups previous release. Example:

ctcli upgrade /path/to/package.tar.gz

Creates a tmp dir and extracts the archive. Then it creates oci image configs and rootfs folders. Next it checks diff between apps in package and apps in current release and prompts for upgrade. If user decided to upgrade, creates a backup, deletes apps from current release and copies files from tmp folder to current release.

delete

Deletes a release completely. Example:

ctcli delete

start

Starts current installation. Example:

ctcli start [app]

stop

Stops current installation. Example:

ctcli stop [app]

logs

Shows logs (stdout/stderr) of specified service. Example:

ctcli logs <app>

status

Show current status. Example:

ctcli status

backup

Makes an archive containing current-release/, data/ and config/ folders and puts it into releases/ folder

ctcli backup

release-info

Shows current release app list and each app version

ctcli release-info

To Be Done

rollback

Install previous release

ctcli rollback

list-releases

Shows full list of releases and highlights current release.

ctcli list-releases

Root Directory File Structure

/releases - Previous releases and etc.
/config - Services' configs
/current-release - Current installation
/logs - Logs
/data - app persistent data
/tmp - Temporary directory

Package structure

meta.json   - contains PackageMeta object and has commitSha, imageTag and etc
package/    - contains package content
    ./runc.amd64    - runc binary
    ./umoci.amd64   - umoci binary
    ./apps          - apps in container
        ./{app}     - app in package
            ./package-config.json   - contains AppPackageConfig object
            ./version.json          - contains info about app image version 
            ./skopeo                - contains oci image that umoci will then extract

Backups

Backup is an archive and has following structure:

/config     - app configs
/apps       - apps
/data
Similar Resources

A simple CLI tool that outputs the history of connections to Amazon EC2 instances using AWS Session Manager.

ssmh This is a simple CLI tool that outputs the history of connections to Amazon EC2 instances using AWS Session Manager. Installation brew install mi

Dec 10, 2021

git-xargs is a command-line tool (CLI) for making updates across multiple Github repositories with a single command.

git-xargs is a command-line tool (CLI) for making updates across multiple Github repositories with a single command.

Table of contents Introduction Reference Contributing Introduction Overview git-xargs is a command-line tool (CLI) for making updates across multiple

Dec 31, 2022

git-xargs is a command-line tool (CLI) for making updates across multiple GitHub repositories with a single command

git-xargs is a command-line tool (CLI) for making updates across multiple GitHub repositories with a single command

git-xargs is a command-line tool (CLI) for making updates across multiple GitHub repositories with a single command. You give git-xargs:

Feb 5, 2022

A command line tool for simplified docker volume command built with go

dockervol A command line tool for simplified docker volume command built with go. Features: Remove anonymous volume (beta) Remove volume by matching n

Dec 18, 2021

fofax is a fofa query tool written in go, positioned as a command-line tool and characterized by simplicity and speed.

fofax is a fofa query tool written in go, positioned as a command-line tool and characterized by simplicity and speed.

fofaX 0x00 Introduction fofax is a fofa query tool written in go, positioned as

Jan 8, 2023

Go package to make lightweight ASCII line graph ╭┈╯ in command line apps with no other dependencies.

Go package to make lightweight ASCII line graph ╭┈╯ in command line apps with no other dependencies.

asciigraph Go package to make lightweight ASCII line graphs ╭┈╯. Installation go get github.com/guptarohit/asciigraph Usage Basic graph package main

Jan 8, 2023

Dev-spaces - A CLI to help creating development environments using AWS Spot Instances

This is a CLI to help creating on-demand development spaces using EC2 Spot Intances.

Nov 9, 2022

Package command provide simple API to create modern command-line interface

Package command Package command provide simple API to create modern command-line interface, mainly for lightweight usage, inspired by cobra Usage pack

Jan 16, 2022

Watcher - A simple command line app to watch files in a directory for changes and run a command when files change!

Watcher - Develop your programs easily Watcher watches all the files present in the directory it is run from of the directory that is specified while

Mar 27, 2022
Comments
  • Problems at startup, most likely problems in runc

    Problems at startup, most likely problems in runc

    Kernel version - 3.10.0-1127.18.2.el7 OS - Fedora 7.8 trace

    ./runc.amd64 --root /opt/crafttalk/packaging/runc-root --debug run -b apps/filestorage filestorage
    

    image

  • add prompt message for starting ElasticUtility start command

    add prompt message for starting ElasticUtility start command

    example:

    root@node1:% ctcli run elasticutility
    elasticutility is not a service - for one time run type:
    ./runc.amd64 start elasticutility update ...some commands
    
  • Оптимизация процесса бэкапов

    Оптимизация процесса бэкапов

    все еще долго, подумать как можно сделать побыстрее плюсом вылетают ошибки, подозреваю что из за неостановки сервисов перед бэкапом, вызывать стоп в таком случае (наверное) image

  • nonroot containers not working

    nonroot containers not working

    tried to add a user on host with the required data - no result. screen with id owner in runc-config image

    if i change this on 0:0 owner everything will be fine. but I do not need this, I want to use the user inside the container. getting error with different startup methods.

    level=error msg="container_linux.go:367: starting container process caused: setup user: cannot set uid to unmapped user in user namespace"
    
Related tags
textnote is a command line tool for quickly creating and managing daily plain text notes.

textnote is a command line tool for quickly creating and managing daily plain text notes. It is designed for ease of use to encourage the practice of daily, organized note taking. textnote intentionally facilitates only the management (creation, opening, organizing, and consolidated archiving) of notes, following the philosophy that notes are best written in a text editor and not via a CLI.

Jan 2, 2023
A twitch focused command line tool for producing, archiving and managing live stream content. Built for Linux.

twinx is a live-streaming command line tool for Linux. It connects streaming services (like Twitch, OBS and YouTube) together via a common title and description.

Oct 17, 2022
MyApps is a universal command line tool for managing manually installed applications.
MyApps is a universal command line tool for managing manually installed applications.

MyApps MyApps is a universal command line tool for managing manually installed applications. Disclaimer I wrote this tool over two long nights while p

Jul 15, 2022
Command Line Tool for managing Apache Kafka

kafkactl A command-line interface for interaction with Apache Kafka | Features command auto-completion for bash, zsh, fish shell including dynamic com

Dec 30, 2022
e2d is a command-line tool for deploying and managing etcd clusters, both in the cloud or on bare-metal

e2d is a command-line tool for deploying and managing etcd clusters, both in the cloud or on bare-metal. It also includes e2db, an ORM-like abstraction for working with etcd.

Aug 23, 2022
CLI for SendGrid, which helps in managing SSO users, can install and update users from yaml config

Sendgrid API This script is needed to add new users to SendGrid as SSO teammates. Previously, all users were manually added and manually migrating the

Jul 20, 2022
An open-source GitLab command line tool bringing GitLab's cool features to your command line
An open-source GitLab command line tool bringing GitLab's cool features to your command line

GLab is an open source GitLab CLI tool bringing GitLab to your terminal next to where you are already working with git and your code without switching

Dec 30, 2022
A command line tool to prompt for a value to be included in another command line.

readval is a command line tool which is designed for one specific purpose—to prompt for a value to be included in another command line. readval prints

Dec 22, 2021
A client for managing authzed or any API-compatible system from your command line.

zed A client for managing authzed or any API-compatible system from your command line. Installation zed is currently packaged by as a head-only Homebr

Dec 31, 2022
Download and install binaries from GitHub Releases, interactively.

bget Download and install binary files from GitHub Releases. Preview Install For Mac/Linux users, you can use Homebrew to install it: brew install ego

Aug 24, 2022