@pietert/cyran
v0.5.8
Published
Release Automation tool for Streetsmart
Downloads
6
Readme
Release automation
Setup
Install
Using NPM
npm i -g @pietert/cyran
or using Yarn
yarn add -g @pietert/cyran
Configure
Now run
cyran init
You will be asked for:
- Jira endpoint: this should be in the form of
https://company_name.atlassian.net
- username: your email that you use to login to Jira
- apiToken: you can create your token here.
- git repository name
- Github username - the username you use to login to GitHub
- Github Personal Access Token - You can create one here
- Jenkins endpoint - the url of the Jenkins build server
- Streetsmart API clientId - the clientId that is used to register the redirect urls
- IdentityServer apiKey - the apiKey that is used to register redirect urls.
- Lastly, you will be asked to authenticate using the Microsoft auth flow. This is required for the application to be able to send emails on your behalf.
Commands
Note: the alias for every command below is after the pipe character.
Triggering a release
cyran release|rel [version]
Checking if a release exists in Jira
cyran release-exists|re <version>
Sending out a release-planning or release-notes email
cyran send-email|se <ReleaseEmailType> <version>
where the ReleaseEmailType
parameter can be 'release-planning'
or 'release-notes'
Manually registering the redirect urls
cyran register-redirects|rr <version>
For help and more info
cyran - h;
FAQ
I get node-gyp errors during install; how do I solve this?
This package relies on the node-gyp
package. It is recommended to update this package by running npm i -g node-gyp
. The latest node-gyp package requires you to have Python 3 installed and Microsoft Visual Studio 2015 or higher. If node-gyp can't find these two dependencies, run npm config edit
. Add the following code to it and save the config.
python=[PATH_TO_PYTHON.exe]
msvs_version={YOUR_VISUAL_STUDIO_VERSION}
Please see this SO answer for more info.
The script can't connect to the Jenkins endpoint
Please make sure you have turned on a VPN connection if your Jenkins server is behind a VPN.
Error No project could be found with key 'STREET'.
If you get the error No project could be found with key 'STREET'.
, make sure you are logged in on Atlassian / JIRA with the Cyclomedia / Microsoft account. If you use for instance Trello on a personal email, it could be logged in with that user.
TODO
- [ ] When script fails at a certain stage, save state so that when you restart the script it automatically resume where it left off.
- [ ] Replace
@azure/identity
package which hand-rolled auth solution to prevent requesting users to log in everytime they start a release. - [ ] Check for new version of script on startup.
- [ ] Automate step 1 of the release procedure