kind: pipeline name: default steps: - name: Run rspec image: ruby:2.6 commands: - bundle - bundle exec rspec when: event: - pull_request - name: Bump and tag image: quay.io/openware/sdk-citools:2.3.1 environment: BOT_USERNAME: kite-bot BOT_NAME: Kite Bot BOT_EMAIL: kite-bot@heliostech.fr BRANCH_NAME: ${DRONE_BRANCH} REPO_NAME: ${DRONE_REPO} GITHUB_API_KEY: from_secret: kite_bot_key commands: - BUNDLE_GEMFILE=/sdk/Gemfile bundle exec rake --rakefile=/sdk/Rakefile ci:prebuild when: branch: - master - "*stable" - name: Publish to RubyGems image: ruby:2.6 environment: RUBYGEMS_API_KEY: from_secret: rubygems_api_key commands: - mkdir ~/.gem - | echo "---\n:rubygems_api_key: $RUBYGEMS_API_KEY" > ~/.gem/credentials - chmod 0600 ~/.gem/credentials - bundle --jobs $(nproc) - bundle exec gem build kite.gemspec - bundle exec gem push kite-$DRONE_TAG.gem when: event: - tag image_pull_secrets: - dockerconfigjson