kind: pipeline
type: docker
name: 1
platform:
  os: linuxs
  arch: amd64
steps:
- name: maven
  image: maven:3-jdk-10
  volumes:
    - name: cache 
      path: /root/.m2 
  commands:
    - mvn install -DskipTests=true

- name: run 
  image: maven:3-jdk-8 
  volumes:
    - name: cache 
      path: /root/.m2 
  commands: 
    - nohup mvn tomcat7:run &

volumes:
  - name: cache 
    host:
      path: /var/lib/cache

trigger:
  branch:
  - master
  event:
  - push
  - pull_request
