Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
113 changes: 0 additions & 113 deletions .circleci/config.yml

This file was deleted.

14 changes: 0 additions & 14 deletions .circleci/pylint

This file was deleted.

File renamed without changes.
48 changes: 48 additions & 0 deletions .github/workflows/lint-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
---

name: Lint and Test

on:
push:
branches-ignore:
- main
pull_request:
types: [ opened, synchronize, reopened ]
branches: [ main ]
workflow_dispatch: {}

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

jobs:
lint-and-test:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
python-version: [ 3.12 ]
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pipenv"

- name: Install pipenv
run: curl https://raw.githubusercontent.com/pypa/pipenv/master/get-pipenv.py | python

- name: Install dependencies
run: pipenv install --dev

- name: Check Airflow Constraints
run: make compare-dependencies

- name: Lint the role
run: make lint

- name: Run Pytest
run: make test
50 changes: 50 additions & 0 deletions .github/workflows/prod-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---

name: Prod Deploy

on:
push:
tags:
- "v*.*.*"
workflow_dispatch: {}

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

env:
COB_DATAPIPELINE_BRANCH: ${{ github.ref_name }}

jobs:
prod-deploy:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
python-version: [ 3.12 ]
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pipenv"

- name: Install pipenv
run: curl https://raw.githubusercontent.com/pypa/pipenv/master/get-pipenv.py | python

- name: Install dependencies
run: pipenv install --dev

- name: Run Ansible Airflow Playbook for Prod
run: |
cd ..
git clone --single-branch --branch main https://github.com/tulibraries/ansible-playbook-airflow.git
cd ansible-playbook-airflow
pipenv install
pipenv run ansible-galaxy install -r requirements.yml
cp .github/.vault ~/.vault;
chmod +x ~/.vault
pipenv run ansible-playbook -i inventory/prod playbook.yml --tags "jumphost,role::airflow::dags" --vault-password-file=~/.vault -e 'ansible_ssh_port=9229' -e cob_datapipeline_branch=$COB_DATAPIPELINE_BRANCH
47 changes: 47 additions & 0 deletions .github/workflows/qa-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---

name: QA Deploy

on:
push:
branches:
- main
workflow_dispatch: {}

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

jobs:
qa-deploy:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
python-version: [ 3.12 ]
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pipenv"

- name: Install pipenv
run: curl https://raw.githubusercontent.com/pypa/pipenv/master/get-pipenv.py | python

- name: Install dependencies
run: pipenv install --dev

- name: Run Ansible Airflow Playbook for QA
run: |
cd ..
git clone --single-branch --branch qa https://github.com/tulibraries/ansible-playbook-airflow.git
cd ansible-playbook-airflow
pipenv install
pipenv run ansible-galaxy install -r requirements.yml
cp .github/.vault ~/.vault;
chmod +x ~/.vault
pipenv run ansible-playbook -i inventory/qa playbook.yml --tags "jumphost,role::airflow::dags" --vault-password-file=~/.vault -e 'ansible_ssh_port=9229'
Loading