Author's Note :This blog post only addresses CloudBees Jenkins Distribution and CloudBees Jenkins Support . For information about other CloudBees’ Jenkins-based products, please refer to the State of Jenkins Configuration as Code (JCasC) support in CloudBees products FAQ article .
We’re thrilled to announce the availability of the Jenkins Configuration as Code (JCasC) plugin as a technical preview for CloudBees Jenkins Distribution and CloudBees Jenkins Support customers. The plugin manages Jenkins instances using YAML-based configuration files. Starting with the September release, Jenkins Configuration as Code is available as a Tier 2 (Compatible) plugin in the CloudBees Assurance Program .
What is Jenkins Configuration as Code?
The Jenkins Configuration as Code plugin permits you to configure Jenkins using YAML files. These files can be stored in a source control management system, and hence all software development best practices can be applied: versioning of configurations, test automation for changes, CI/CD and even continuous deployment. The files can be stored along with other configuration definitions (Ansible playbooks, Helm charts, or Pipeline scripts), so it is possible to define the entire CI/CD infrastructure as code. The Jenkins Configuration as Code plugin also offers a number of valuable features to simplify instance management:
Configuring global system settings, agents and auto-provisioning clouds, views and other configuration entities
Credentials management and external credentials source support
Support of configuration export from Jenkins instances
CLI and REST API for configuration management, pre-flight validation and dry-run
Support of many plugins out-of-the-box
Extensive user documentation
Please refer to the JCasC plugin documentation for additional information. There is also a series of articles with feature overview on the CloudBees website:
Anyone who has set up Jenkins and configured all of its plugins properly knows it can be a detailed, time-consuming process, especially when you’re using the “Manage Jenkins” user interface to do everything. A more contemporary way to solve this problem is to use Jenkins Configuration as Code to manage Jenkins instances. This allows you to make use of tools like versioning, code comparison and replication for things that you’d traditionally configure using a point-and-click user interface.
CloudBees Jenkins Distribution or CloudBees Core offer various features to simplify configuration management for Jenkins instances at any scale. To manage these products, it’s also possible to use tools like Ansible or low-level Jenkins features like Groovy hooks. All of these methods are difficult to maintain and create high demand to have an alternative solution which allows for configuring controllers with simple files, preferably in a declarative style. This is how the configuration-as-code research started on the CloudBees side.
The Jenkins Configuration as Code plugin was originally started as a joint research project by CloudBees and Praqma. Nicolas De Loof and Ewelina Wilkosz were the initial champions of this project, and the 1.0 version was officially released in September 2018. It received huge traction in the community, and a lot of contributors have joined the project. I would like to specifically mention Joseph Petersen and Tim Jacomb who stepped up to become the plugin maintainers and moved the project forward. Just one week ago, the project hit the 100 contributors mark . This number does not even include contributions to other components to improve JCasC compatibility in individual plugins. This has been, and still is, a massive effort in the community, and we are happy to be a part of it.
What about CloudBees?
Since the JCasC Plugin was officially released, CloudBees has received dozens of support requests and RFEs about JCasC support in CloudBees products. Beginning September 2018 the plugin was available to all customers as a Tier 3 (Community) plugin with limited support, but the plugin still needed to pass the internal certification process to get higher support tier and to become a part of the CloudBees Assurance Program.
Over the last couple of months, CloudBees engineers have actively contributed to the Jenkins Configuration as Code Plugin ecosystem in order to ensure the stability, compatibility and security of the plugin. At the same time, we set up internal verification flows in order to ensure a high degree of compatibility with other CloudBees products and to make the plugin part of the CloudBees Assurance Program. We have also been working on public documentation and expanding our internal knowledge base, as well as support enablement to provide the best, high quality support experience to our customers. We have made a lot of progress on this front, and we are excited to finally make this feature available to CloudBees users and customers as a part of our product offering. The plugin is now available as a technical preview, but the intent is to make it a fully supported component across the entire CloudBees suite.
What does a technical preview mean?
Currently the Configuration as Code plugin is certified as a Tier 2 (Compatible) plugin. It means that the plugin is supported by CloudBees. Please refer to CloudBees Plugin Support Policies for full information about support levels and SLAs for the plugin.
CloudBees will process support requests related to the Jenkins Configuration as Code plugin. Standard support channels can be used to report issues or to submit requests for enhancement.
CloudBees will process support requests related to plugin compatibility with the JCasC plugin.
Resolution of reported issues is subject to CloudBees internal priorities.
The plugin has not undergone full end-to-end testing with all CloudBees products.
The plugin is not enabled by default, but it can be installed by means of the plugin manager interface or using other features available in CloudBees products.
We welcome your feedback about the plugin and invite early adopters to try it out on their instances. Configuration as code is an area of active development so now is a good time to submit bug reports and to hopefully see a rapid turn around. We will provide the best possible support to users of the feature.
If you are a Cloudbees Jenkins Support customer using the Jenkins LTS release line, please follow the Jenkins Configuration as Code Plugin documentation. The plugin can easily be installed from the Jenkins update center and then configured on the instance. If you use Docker, the plugin can also be installed using a standard install-plugins.sh script available in the official Docker images. Note that JCasC does NOT support plugin management on its own, and auxiliary solutions are still required to install plugins before the JCasC configuration file gets applied.
If you use CloudBees Jenkins Distribution, you can follow the Configuration as Code quick start guidelines available in the administration manual . There are guidelines available for Dockerized instances and for classic setups. You can also find a demo for Docker here . You can get a first experience with JCasC by simply running this command:
docker run --rm -p 8080:8080 cloudbees/cjd-jcasc-demo
This command will start an immutable Docker container with the CloudBees Jenkins Distribution instance with all major plugins from the CloudBees Assurance Program.
There is a high level of compatibility offered for plugins in the CloudBees Assurance Program. All critical Tier 1 plugin functionality can be managed via configuration as code. Similarly, many Tier 2 plugins are also supported (please see the referenced demo). However, there are still a number of plugins which do not have full JCasC compatibility
Known issues with the Configuration as Code plugin are tracked in t he community Jenkins issue tracke r . Compatibility for plugins from CloudBees Assurance Program is tracked in the following CloudBees-maintained locations (although most plugins are compatible with Configuration as Code):
CloudBees Community Plugins (Tier 3) - see the community issue tracker.
CloudBees engineering teams will keep working on providing full support of JCasC in Jenkins-based products. This includes plugin compatibility, improved stability, improved user experience and new features specifically for CloudBees customers. We are also working on related stories like plugin management in order to make plugin management and configuration even smoother. A technical preview for CloudBees Core client controllers is also expected to become available soon. Stay tuned for the upcoming announcements!
On December 4, 2019 I will be speaking more on this topic at DevOps World | Jenkins World Lisbon . Join me if you are in the neighborhood. Use JWFOSS for 30% discount on registration.
You can find more information about Jenkins Configuration as Code in CloudBees products here:
Stay up to date
We'll never share your email address and you can opt out at any time, we promise.