Advertisement
Guest User

Untitled

a guest
Apr 20th, 2021
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 1.87 KB | None | 0 0
  1. ---
  2. version: 2
  3. plan:
  4.   project-key: NOAHSPIN
  5.   key: AUMLOADER
  6.   name: Spinnaker Aum Loader
  7.  
  8. stages:
  9.   - Build and publish app:
  10.       jobs:
  11.        - BuildAndTest
  12.         - DockerCleanup
  13.  
  14. BuildAndTest:
  15.   tasks:
  16.     - script:
  17.        - yarn install
  18.         - npm run generateBuildName
  19.         - npm test
  20.         - npm pack
  21.         - npm publish
  22.         - npm run tag
  23.     - inject-variables:
  24.         file: .version
  25.         scope: RESULT
  26.         namespace: build
  27.     - test-parser:
  28.         type: mocha
  29.         test-results:
  30.          - "mocha.json"
  31.   docker:
  32.     image: our.docker.registry.com/node-8-builder-new:latest
  33.     volumes:
  34.       ${bamboo.working.directory}: /mnt/code/
  35.       /mnt/bamboo-agent/cache/node_modules/: /mnt/code/node_modules/
  36.       /mnt/bamboo-agent/cache/npmrc/.npmrc: /mnt/code/.npmrc
  37.   artifacts:
  38.     - name: Default
  39.       pattern: .version
  40.  
  41. DockerCleanup:
  42.   tasks:
  43.     - script:
  44.        - docker system prune -a -f
  45.     - clean
  46.  
  47. ---
  48. version: 2
  49. deployment:
  50.   name: Deploy spinnaker aum loader on DEV
  51.   source-plan: NOAHSPIN-AUMLOADER
  52.  
  53. release-naming:
  54.   next-version-name: ${service-name}-${bamboo.build.npm.version}-develop-${bamboo.buildNumber}
  55.  
  56. environments:
  57.  - DEV
  58.  
  59. DEV:
  60.   tasks:
  61.     - script:
  62.        - git clone ssh://git@out.git.server.com:7999/noahcore/noah-deploy.git
  63.         - cd noah-deploy
  64.         - jq ".dependencies.\"$service-name\" = \"${bamboo.build.npm.version}\"" package.json | sponge package.json
  65.         - git add package.json
  66.         - git commit -m "[Bamboo] Automatic version bump for $service-name in DEV"
  67.         - git push
  68.         - clean
  69.     - script: |
  70.        #!/bin/bash
  71.         ssh mlp_noah_dev << EOF
  72.           sudo -H -u svc_spinnaker_dev
  73.           cd $HOME
  74.           source .bashrc
  75.           carryall deploy
  76.         EOF
  77.   triggers:
  78.     - build-success:
  79.         branch: develop
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement