Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Circular dependency in build/test/deployment pipeline #25

Open
benlangfeld opened this issue Sep 5, 2014 · 1 comment
Open

Circular dependency in build/test/deployment pipeline #25

benlangfeld opened this issue Sep 5, 2014 · 1 comment
Assignees

Comments

@benlangfeld
Copy link
Member

adam_cookbook is supposed to be an installer, based on Chef, for Adam Snark Rabbit and his dependencies, either as an all-in-one or selecting individual components. There are several problems with this, and one is a circular dependency.

Adam has two types of dependencies:

  • Internal (Ruby, gem installation, etc)
  • External (XMPP/RabbitMQ/FreeSWITCH/nginx)

Currently the app project uses the cookbook to provision development/testing environments for the following reasons:

  • Local development requires the ability to run the full application in an isolated, provisioned environment and thus requires both internal and external dependencies.
  • The applications' test suites require internal and external dependencies both locally both in CI.

The installer, of course, also relies on the content of the application repository in order to actually install it. This means coordination overhead between the two projects and being circular this is tricky.

Ideally, the close concerns for testing the apps should be contained with the apps themselves, and the apps should be packaged in such a way that they have no internal dependencies that require separate installation, making deployment easier. The external test dependencies should be provided independently from the installer, either composition of sub-projects or as loosely-related resources provided either by the CI system itself or by other means.

@benlangfeld benlangfeld self-assigned this Sep 5, 2014
@benlangfeld benlangfeld reopened this Sep 5, 2014
@benlangfeld
Copy link
Member Author

The CI pipeline would ideally run the app's test suites in a totally isolated environment (eg a Docker container just for the app) and follow up by packaging from that.

Options for packaging the apps with their dependencies are:

OS packages - pkgr or Omnibus

  • + More general format (can be installed in a wider variety of environments, including a container image)
  • + Hosted (pkgr only, http://packager.io) and open-source options
  • - Encourages diversion from 12factor principles on some points (eg log storage)
  • - Requires a multi-stage build and potentially multiple build artefacts

Linux container images: Docker + Heroku buildpacks

  • + Contains everything down to the OS necessary for running the application
  • + Encourages higher degree of isolation
  • + Hosted (https://quay.io/, Docker Hub Private) and open-source (Docker, private docker registry) options
  • - Cannot decompose

In all cases, the hosted options all provide distribution (package repository / Docker registry) but we would have to provide this were we to use our own build pipeline. Additionally, http://packager.io and http://quay.io build the package, but neither appears to support a test step to use as real CI. If we stick to Jenkins, we have to build these the pipeline and distribution ourselves, but I do not know of any open-source CI services which will do both packaging and testing in one step.

benlangfeld added a commit that referenced this issue Sep 8, 2014
benlangfeld added a commit that referenced this issue Sep 8, 2014
This hasn't been used in a long time since the cookbook/installer is now external to the application.

#25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant