-
Notifications
You must be signed in to change notification settings - Fork 5
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
Introduce a new component: worker which performs the real builds #260
Open
jawher
wants to merge
49
commits into
develop
Choose a base branch
from
workers
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- bzk service restart == bzk service stop && bzk service start - Rename tag option by version on bzk service start - Add --recreate options on bzk service restart which destroy container before restarting it
WARNING This PR needs docker experimental features, mainly syslog-tag support, which was merged after the 1.7 release. What remains to be done:
|
Rewrite bzk service
Uses unordered lists instead of tables
When showing variant list, selected row is highlighted, and unselected rows are lightened
Some minor changes in color
During a build, the created directories (build, shared source, ...) were created using 0644 permissions instead of 0755. What's really weird is that it used to work in VirtualBox VMs, but fails (which is to be expected) in VMWare VMs.
The API (and therefore the CLI) now only expose 2 operations: get and set an SCM key on a project. This PR also includes a bit of cleanup/refactoring on the mongo db code
Self explanatory diff. Oops !
In order to fix spurious mongoldb data corruption which can occur with no grace. The server component was also modified to listen to and handle the SIGTERM signal docker sends to containers when stopping them, to avoid blocking for the duration of the grace period before stopping.
Make go vet happy
Fix created directories permissions
Fix a JSON config bug in Variant struct
…ntainers Add a 5 second grace period when stopping the bazooka containers
Tweak SCM key handling
Rework jobs and variants lists for a more responsive layout
I'm working on splitting the work done here into smaller and more manageable pull requests. I can see 3 macro parts:
|
This internal API is intended to be used by orchestration to manipulate jobs and variants using only the API instead of mongo
This will be needed for orchestration and parser to retrieve the required images using the API instead of mongo
The error was caused by parsing the json body into a map, whereas the validator (automatically invoked) expects a struct
Add an API to serve a specific image given its name
Add an internal API to manipulate jobs and variants
Use syslog to capture the build log
Closes #6
Implement service aliases
In order to do things like nark jobs and variants as finished, add SCM info, ...
…ongo Orchestration now uses the HTTP API instead of mongo
… use Instead of a hard-coded list of images
Parser now use the image API to retrieve the language parser image to use
Bazooka will now systematically use a defer function to remove containers created during the build of a projet This function is common to all the modules, and is available in commons/container.go Closes #271
Use defer to remove containers
Tests files are not used by any tests, and are outdated anyway
Homogenize to use URL instead of URI
Update generator to manage changes in working directory
Use templates to generate bzk build scripts and Dockerfile
Add error details when logging scm fetch error
* Use new json format * fix the startJob that was blocking
Fix bitbucket server hook
Bazooka used to rely on links to work: * The DB container was linked into the server container * The server container was linked into the web container This PR proposes to replace these links (which are to be considered a deprecated and legacy feature in Docker) with the usage of bridge networks: `bzk service start` will create a `bzk_net` network if it doesn't exist, and attach the db, server and containers to it for them to be able to communicate. The build flow was also modified so that the various build containers (orchestration, parser, ...) are attached to the same network when started. This PR alos adds a working docker compose config capable of starting bazooka using docker compose.
through a queue (using beanstalkd) Only server now has access to mongo. All other components go through the REST api. The build log is now captured using the syslog logging driver for dockeOnly server now has access to mongo. All other components go through the REST api. The build log is now captured using the syslog logging driver for docker
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
through a queue (using beanstalkd)
Only server now has access to mongo. All other components go through
the REST api.
The build log is now captured using the syslog logging driver for
dockeOnly server now has access to mongo. All other components go
through the REST api.
The build log is now captured using the syslog logging driver for docker