npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@k8ty-app/k8ty

v0.0.1

Published

Deploy apps to k8s quickly

Downloads

3

Readme

k8ty

Deploy apps to k8s quickly

oclif Version Downloads/week License

Command usage is directly below, but for a broader overview, please see:

Usage

$ npm install -g @k8ty-app/k8ty
$ k8ty COMMAND
running command...
$ k8ty (-v|--version|version)
@k8ty-app/k8ty/0.0.1 darwin-arm64 node-v15.12.0
$ k8ty --help [COMMAND]
USAGE
  $ k8ty COMMAND
...

Commands

k8ty app:create

Create a new k8ty.app

USAGE
  $ k8ty app:create

OPTIONS
  -i, --image=image  The image of your app
  -p, --port=port    The container port you app runs on

See code: src/commands/app/create.ts

k8ty app:delete [NAME]

Delete an app

USAGE
  $ k8ty app:delete [NAME]

See code: src/commands/app/delete.ts

k8ty app:list

List all apps

USAGE
  $ k8ty app:list

See code: src/commands/app/list.ts

k8ty app:status [APP]

USAGE
  $ k8ty app:status [APP]

See code: src/commands/app/status.ts

k8ty app:update [APP]

Set the value of a config variable

USAGE
  $ k8ty app:update [APP]

OPTIONS
  -i, --image=image  The image of your app
  -p, --port=port    The container port you app runs on

See code: src/commands/app/update.ts

k8ty config:delete [ENV]

Remove a config variable

USAGE
  $ k8ty config:delete [ENV]

OPTIONS
  -a, --app=app  (required) The name of the app

See code: src/commands/config/delete.ts

k8ty config:get [ENV]

Get the value of a config variable

USAGE
  $ k8ty config:get [ENV]

OPTIONS
  -a, --app=app  (required) The name of the app

See code: src/commands/config/get.ts

k8ty config:list

List the config variables for an app

USAGE
  $ k8ty config:list

OPTIONS
  -a, --app=app  (required) The name of the app

See code: src/commands/config/list.ts

k8ty config:set [ENV] [VAL]

Set the value of a config variable

USAGE
  $ k8ty config:set [ENV] [VAL]

OPTIONS
  -a, --app=app  (required) The name of the app

See code: src/commands/config/set.ts

k8ty hello [FILE]

describe the command here

USAGE
  $ k8ty hello [FILE]

OPTIONS
  -f, --force
  -h, --help       show CLI help
  -n, --name=name  name to print

EXAMPLE
  $ k8ty hello
  hello world from ./src/hello.ts!

See code: src/commands/hello.ts

k8ty help [COMMAND]

display help for k8ty

USAGE
  $ k8ty help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

Overview

k8ty is a cli app to help you quickly deploy stateless apps to a kubernetes cluster. For example, if you call k8ty app:create and will generate a k8ty-app with some heroku-like name (via Haikunator) like traveling-whisper-123456. So, what is a k8ty-app, in kubernetes terms?

Anatomy of a k8ty-app

A k8ty-app creates the following kubernetes resources (all namespaced and generally named after the app's namesake):

  • namespace
  • secret
  • deployment
  • service
  • ingress

All resourced are put in and labeled in the namespace created. An empty secret is also generated. A deployment is created with a stock image (currently nginx), exposing port 80 (named http) (overridable via flags on creation, and updatable). This deployment has and envFrom relationship to the secret, so any/all values in the secret will be mounted as environment variables in the deployment/pods. A service is created with port 80 that maps to the http named port of the deployment, and an ingress is created to point to that services port.

Assuming you've taken care of the Prerequisites, this means your traveling-whisper-123456 app will (near) immediately be available at https://traveling-whisper-123456.yourdomain.com after creation!

Prerequisites

You will need to have the following things set up to make use of this app:

  • A kubernetes cluster + kubectl configured
  • Deploy the nginx ingress controller: for ingress routing
    • This should have a public Load Balancer attached to it!
  • Deploy CertManager: for automated SSL certificated via Let's Encrypt
  • Point a wildcard DNS record to your Load Balancer: This lets *.yourdomain.com route to your ingress controller