ruby-rails orb is a CircleCI orb that is optimized for DLSS Infrastructure Ruby / Rails projects.
This includes:
- Using Postgres for a database.
- Using Code Climate for code coverage.
- Validating openapi specifications.
- Building Docker images.
- Code climate reporter test id added as a CircleCI project environment variable as
CC_TEST_REPORTER_ID
. - Docker username and password added to a CircleCI context as
DOCKER_USER
andDOCKER_PASS
.
$ circleci orb pack src > orb.yml
$ circleci orb validate orb.yml
Orb changes can be testing using an inline orb:
- Make your changes.
- Pack the orb with
circleci orb pack src > orb.yml
. - In the
config.yml
of a project repository, replace the orb reference (e.g.,ruby-rails: sul-dlss/[email protected]
) to an inline orb copied fromorb.yml
:
orbs:
ruby-rails:
orbs:
docker: circleci/[email protected]
node: circleci/[email protected]
ruby: circleci/[email protected]
browser-tools: circleci/[email protected]
executors:
ruby:
description: Ruby-only executor.
...
- Commit the test
config.yml
to a branch and let it execute on CircleCI.
- Create and push a branch with your new features.
- When ready to publish a new production version, create a Pull Request from feature branch to
main
. - The title of the pull request must contain a special semver tag:
[semver:<segment>]
where<segment>
is replaced by one of the following values.
Increment | Description |
---|---|
major | Issue a 1.0.0 incremented release |
minor | Issue a x.1.0 incremented release |
patch | Issue a x.x.1 incremented release |
skip | Do not issue a release |
Example: [semver:major]
- Squash and merge. Ensure the semver tag is preserved and entered as a part of the commit message.
- On merge, after manual approval, the orb will automatically be published to the Orb Registry.
For further questions/comments about this or other orbs, visit the Orb Category of CircleCI Discuss.
- Orb Author Intro
- CircleCI Orb Docs - Docs for using and creating CircleCI Orbs.