Skip to content

Instantly share code, notes, and snippets.

@goern
Last active September 24, 2015 15:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save goern/d8910ba7a10ff26bc8f2 to your computer and use it in GitHub Desktop.
Save goern/d8910ba7a10ff26bc8f2 to your computer and use it in GitHub Desktop.

Nulecule Lifecycle Definition

install - will install all required artifacts into a working changes. it will not alter the configuration [of OpenShift or Kubernetes] via a provider. a deployment guy will be able to configure the deployment process, which will be started by run.

run - will deploy artifacts and their configuration via the provider onto the platform. configuration will become effectice and the application will be available to users.

stop - will disable access to the application for users. configuration will remain deployed to the platform but not be effective.

uninstall - artifacts will be removed from the platform

The tool used to maintaine an Atomic App will not take care about cleaning up the current directory. It will also try to keep the pollution minimal, eg not unpack more than nessecary [to configure the application’s artifacts] into the current directory.

@aweiteka
Copy link

aweiteka commented Aug 6, 2015

Comments:

  1. Remove atomic from each item. Generalize to install|run, etc
  2. Title: Nulecule Lifecycle Definition or something.
  3. Regarding install I think we might back away from the current working directory. I'll get the conversation going again here. projectatomic/atomicapp#142

@jasonbrooks
Copy link

I read the conversation in issue #142 -- I keep thinking that "install" is a bad term for what it does -- what about a term like "unpack" or "extract" instead of install?

Install seems like it'd make sense in a docker provider context, where things like putting a systemd service file in place, pulling images, and extracting files into a sane location might happen...

@goern
Copy link
Author

goern commented Aug 7, 2015

@jasonbrooks an "unpack" needs to be implemented for the atomic tool and does not make any sense in other contexts. But I agree, it feels clumsy

@goern
Copy link
Author

goern commented Aug 7, 2015

@aweiteka gist updated

@LalatenduMohanty
Copy link

I think the title "Nulecule Lifecycle Definition" is not correct. The lifecycle is applicable to a container app that is described using the Nulecule specification.

@aweiteka
Copy link

aweiteka commented Aug 7, 2015

@jasonbrooks @goern I agree 'install' is clumsy. We can rename 'install' to whatever we want in atomicapp and nulecule but we are constrained from a practical perspective by the atomic CLI, which has labels for install, run, uninstall. If we want something like 'unpack' then it needs to be defined here first[1], then be implemented in atomic CLI.

[1] https://github.com/projectatomic/ContainerApplicationGenericLabels

@dustymabe
Copy link

@aweiteka I think the right thing to do is to try to get a label added to the atomic CLI. Maybe that is a big deal and not easy to do. Maybe not. I think we should try though.

@LalatenduMohanty
Copy link

From Atomic App point view, should atomic uninstall first stop the containers and then remove them?

@vpavlin
Copy link

vpavlin commented Sep 2, 2015

Crazy idea - what if we propose addition of arbitrary verbs to atomic via labels?

  1. You call atomic unpack
  2. atomic figures out it's not any of known verbs and thus tries to check image labels for io.projectatomic.atomic.cmd.unpack=.*
  3. Not found? No problem, fail. Found? Call whatever is specified there. unpack itself is kinda specific to our use case and I don't see it very well acceptable for atomic's generic use case. But being able to define own commands might be the right way

@dustymabe
Copy link

We talked about this today.. see projectatomic/atomicapp#290

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