From e3b202825b402ccb76cd0727df70ab562a36b0fc Mon Sep 17 00:00:00 2001 From: KKlochko Date: Thu, 3 Aug 2023 13:47:34 +0300 Subject: [PATCH] Add the CI/CD configuration. --- .drone.yaml | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++ CHANGELOG.org | 2 ++ 2 files changed, 54 insertions(+) create mode 100644 .drone.yaml diff --git a/.drone.yaml b/.drone.yaml new file mode 100644 index 0000000..a09293b --- /dev/null +++ b/.drone.yaml @@ -0,0 +1,52 @@ +kind: pipeline +type: docker +name: default + +environment: + DATABASE_NAME: link_shortener_dev + DATABASE_USERNAME: postgres + DATABASE_PASSWORD: postgres + DATABASE_HOST: postgres + DATABASE_PORT: 5432 + SECRET_KEY_BASE: TestSecretKeycRZ1H45gfdAsdf8DIb45df4664mRCruzwVEF68wosddfg324ost + +steps: + - name: install dependencies + image: elixir:1.14.0-slim + volumes: + - name: mix + path: /root/.mix + commands: + - mix local.hex --force + - mix local.rebar --force + - mix deps.get + - mix compile + + - name: run migrations + image: elixir:1.14.0-slim + volumes: + - name: mix + path: /root/.mix + commands: + - mix ecto.setup + + - name: run tests + image: elixir:1.14.0-slim + volumes: + - name: mix + path: /root/.mix + commands: + - mix test + +volumes: +- name: mix + temp: {} + +services: + - name: postgres + image: postgres:15-alpine + environment: + POSTGRES_DB: link_shortener_dev + POSTGRES_USER: postgres + POSTGRES_PASSWORD: postgres + diff --git a/CHANGELOG.org b/CHANGELOG.org index c49a769..84929b2 100644 --- a/CHANGELOG.org +++ b/CHANGELOG.org @@ -40,4 +40,6 @@ Refactor the Links module. ** 0.4.9 <2023-08-02 Wed> Add tests for the Links module. +** 0.4.10 <2023-08-03 Thu> + Add the CI/CD configuration.