Advertisement
Guest User

Untitled

a guest
Nov 12th, 2019
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 2.02 KB | None | 0 0
  1. kind: pipeline
  2. type: docker
  3. name: default
  4.  
  5. steps:
  6.   - name: restore-cache-with-filesystem
  7.     image: meltwater/drone-cache:dev
  8.     pull: true
  9.     settings:
  10.       backend: "filesystem"
  11.       restore: true
  12.       cache_key: "volume"
  13.       archive_format: "gzip"
  14.       # filesystem_cache_root: "/tmp/cache"
  15.       mount:
  16.        - '/drone/src/.m2'
  17.       debug: true
  18.     volumes:
  19.       - name: cache
  20.         path: /tmp/cache
  21.  
  22.   - name: Test With Maven
  23.     image: maven:3.6.1
  24.     environment:
  25.       TEST_MINIO_ACCESS_KEY:
  26.         from_secret: TEST_MINIO_ACCESS_KEY
  27.       TEST_MINIO_SECRET_KEY:
  28.         from_secret: TEST_MINIO_SECRET_KEY
  29.       TEST_MINIO_IS_SSL: "true"
  30.       TEST_MINIO_PORT: "443"
  31.       TEST_MINIO_HOSTNAME: "storage.googleapis.com"
  32.       TEST_DATABASE_NAME: faroseacademy_webapi
  33.       TEST_DATABASE_USERNAME: root
  34.       TEST_DATABASE_PASSWORD: "123456"
  35.       TEST_DATABASE_HOSTNAME: mysql
  36.       TEST_DATABASE_PORT: "3306"
  37.       TEST_MONGO_HOSTNAME: mongo
  38.       TEST_MONGO_PORT: "27017"
  39.     commands:
  40.      - export MAVEN_HOME=/drone/src/.m2
  41.       - export M2_HOME=/drone/src/.m2
  42.       - echo $(ls -lah /drone/src/.m2)
  43.       - mvn test -Dmaven.repo.local=/drone/src/.m2
  44.       - echo $(ls -lah /drone/src/.m2)
  45.  
  46.   - name: rebuild-cache-with-filesystem
  47.     image: meltwater/drone-cache:dev
  48.     pull: true
  49.     settings:
  50.       debug: true
  51.       backend: "filesystem"
  52.       rebuild: true
  53.       cache_key: "volume"
  54.       archive_format: "gzip"
  55.       # filesystem_cache_root: "/tmp/cache"
  56.       mount:
  57.        - '/drone/src/.m2'
  58.     volumes:
  59.       - name: cache
  60.         path: /tmp/cache
  61.  
  62.  
  63. services:
  64.   - name: mysql
  65.     image: mysql:8
  66.     environment:
  67.       MYSQL_ROOT_PASSWORD: "123456"
  68.       MYSQL_DATABASE: "faroseacademy_webapi"
  69.   - name: mongo
  70.     image: mongo:4
  71.     environment:
  72.       MONGO_INITDB_DATABASE: 'faroseacademy_webapi'
  73.  
  74. trigger:
  75.   branch:
  76.    - master
  77.     - integration
  78.   event:
  79.    - push
  80.     - pull_request
  81.  
  82. volumes:
  83.   - name: cache
  84.     host:
  85.       path: /tmp/cache
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement