diff --git a/.drone.yml b/.drone.yml index b6843da..ba5c9a0 100644 --- a/.drone.yml +++ b/.drone.yml @@ -10,6 +10,22 @@ services: POSTGRES_PASSWORD: postgres steps: + - name: restore-cache-with-filesystem + # the `plugins` user seems to be owned by the drone organization + image: docker.io/library/plugins/cache:1.9 + pull: true + settings: + backend: "filesystem" + restore: true + cache_key: "volume" + archive_format: "gzip" + # filesystem_cache_root: "/tmp/cache" + mount: + - "_build" + volumes: + - name: cache + path: /tmp/cache + - name: check image: docker.io/library/elixir:1.18.3-otp-27 commands: @@ -36,8 +52,8 @@ steps: # Wait for postgres to become available - | for i in {1..20}; do - if pg_isready -h postgres; then - break + if pg_isready -h postgres -u postgres; then + exit 0 else true fi @@ -51,8 +67,8 @@ steps: environment: MIX_ENV: test TEST_POSTGRES_HOST: postgres - depends_on: - - wait for postgres + # depends_on: + # - wait for postgres commands: # Install hex package manager - mix local.hex --force