Merge pull request #232 from akrherz/gh298_ofe_groupid #715
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Install and Test | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
jobs: | |
build-linux: | |
defaults: | |
run: | |
# Ensures environment gets sourced right | |
shell: bash -e -l {0} | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Add /etc/hosts entries | |
run: | | |
cat .github/workflows/etchosts.txt | sudo tee -a /etc/hosts | |
# setup conda-forge with micromamba | |
- name: Setup Python | |
uses: mamba-org/setup-micromamba@v1 | |
with: | |
environment-file: environment.yml | |
condarc: | | |
channels: | |
- conda-forge | |
- defaults | |
create-args: >- | |
python=3.12 | |
environment-name: prod | |
cache-environment: true | |
- name: Do Work | |
run: | | |
set -x | |
git clone --depth 1 https://github.com/akrherz/ci_tooling.git .ci_tooling | |
cd .ci_tooling | |
. postgres.sh | |
cd .. | |
psql -c 'CREATE ROLE runner SUPERUSER LOGIN CREATEDB;' -U postgres || true | |
sh bootstrap.sh | |
psql -f data/postgis/cwsu.db -U mesonet postgis | |
python schema_manager.py | |
python store_test_data.py $(which psql) |