Skip to content

Latest commit

 

History

History
62 lines (50 loc) · 1.2 KB

File metadata and controls

62 lines (50 loc) · 1.2 KB

キャッシュの導入

パイプラインの記述(更新)

---
resources:
- name: repo
  type: git
  source:
    uri: https://github.com/making/hello-servlet.git

jobs:
- name: unit-test
  plan:
  - get: repo
    trigger: true
  - task: mvn-test
    config:
      platform: linux
      image_resource:
        type: docker-image
        source:
          repository: maven
      inputs:
      - name: repo
      caches:
      - path: repo/m2   
      run:
        path: bash
        args:
        - -c
        - |
          set -e
          cd repo
          rm -rf ~/.m2
          ln -fs $(pwd)/m2 ~/.m2
          mvn test

パイプラインの設定(更新)

fly -t ws set-pipeline -p hello-servlet -c pipeline.yml

image.png

ジョブの実行

fly -t ws trigger-job -j hello-servlet/unit-test --watch

image.png

fly -t ws trigger-job -j hello-servlet/unit-test --watch

image.png