Skip to content

Commit

Permalink
Merge pull request #36 from ropable/master
Browse files Browse the repository at this point in the history
Additional KMI spatial layer checks
  • Loading branch information
ropable authored Dec 20, 2023
2 parents 9698ea1 + d48f0d5 commit b06f839
Show file tree
Hide file tree
Showing 9 changed files with 731 additions and 491 deletions.
12 changes: 12 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
version: 2
updates:
- package-ecosystem: "pip"
directory: "/"
schedule:
interval: "weekly"
- package-ecosystem: "github-actions"
# Workflow files stored in the
# default location of `.github/workflows`
directory: "/"
schedule:
interval: "weekly"
30 changes: 20 additions & 10 deletions .github/workflows/image-build-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,31 +24,41 @@ jobs:
# Only required for workflows in private repositories
actions: read
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
#----------------------------------------------
# Checkout repo
#----------------------------------------------
- name: Checkout repository
uses: actions/checkout@v3
id: checkout-repo
with:
fetch-depth: 0
uses: actions/checkout@v4
#----------------------------------------------
# Set up Docker BuildX environment
#----------------------------------------------
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
#----------------------------------------------
# Log Docker into the GitHub Container Repository
#----------------------------------------------
- name: Log into registry ${{ env.REGISTRY }}
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
#----------------------------------------------
# Extract Docker image metadata from GitHub events
#----------------------------------------------
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v4
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
flavor: |
latest=true
#----------------------------------------------
# Build and push Docker image (not on PR)
#----------------------------------------------
- name: Build and push Docker image
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
Expand Down
13 changes: 4 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,8 @@ Manage new or updating project dependencies with Poetry also, like so:

# Environment variables

This project uses **django-confy** to set environment variables (in a `.env` file).
The following variables are required for the project to run (others have
default values):

RT_URL=https://resourcetracking.dbca.wa.gov.au
[email protected]
PASS_SSO=password
This project uses **python-dotenv** to set environment variables (in a `.env` file).
Most settings have default values; check `status.py` for required variables.

# Running

Expand All @@ -43,6 +38,6 @@ To build a new Docker image from the `Dockerfile`:

docker image build -t ghcr.io/dbca-wa/healthcheck .

To run a Docker container locally, publishing port 8080 to a different local port:
To run a Docker container locally, publishing container port 8080 to a local port:

docker container run --rm --publish 8211:8080 --env-file .env ghcr.io/dbca-wa/healthcheck
docker container run --rm --publish 8080:8080 --env-file .env ghcr.io/dbca-wa/healthcheck
80 changes: 75 additions & 5 deletions kustomize/overlays/prod/deployment_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ spec:
secretKeyRef:
name: healthcheck-env-prod
key: CSW_API
- name: DBCA_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_GOING_BUSHFIRES_URL
- name: KMI_URL
valueFrom:
secretKeyRef:
Expand All @@ -57,3 +52,78 @@ spec:
secretKeyRef:
name: healthcheck-env-prod
key: TRACKING_POINTS_MAX_DELAY
- name: DBCA_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_GOING_BUSHFIRES_URL
- name: DBCA_CONTROL_LINES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_CONTROL_LINES_URL
- name: DFES_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DFES_GOING_BUSHFIRES_URL
- name: ALL_CURRENT_HOTSPOTS
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: ALL_CURRENT_HOTSPOTS
- name: LIGHTNING_24H
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: LIGHTNING_24H
- name: LIGHTNING_24_48H
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: LIGHTNING_24_48H
- name: LIGHTNING_48_72H
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: LIGHTNING_48_72H
- name: FUEL_AGE_1_6Y
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: FUEL_AGE_1_6Y
- name: FUEL_AGE_NONFOREST_1_6Y
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: FUEL_AGE_NONFOREST_1_6Y
- name: COG_BASEMAP
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: COG_BASEMAP
- name: STATE_BASEMAP
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: STATE_BASEMAP
- name: DBCA_BURN_PROGRAM
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_BURN_PROGRAM
- name: DAILY_ACTIVE_BURNS
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DAILY_ACTIVE_BURNS
- name: DBCA_LANDS_WATERS
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_LANDS_WATERS
- name: DBCA_LANDS_WATERS_INTEREST
valueFrom:
secretKeyRef:
name: healthcheck-env-prod
key: DBCA_LANDS_WATERS_INTEREST
2 changes: 1 addition & 1 deletion kustomize/overlays/prod/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ labels:
variant: prod
images:
- name: ghcr.io/dbca-wa/healthcheck
newTag: 1.1.12
newTag: 1.1.13
patches:
- path: deployment_patch.yaml
- path: service_patch.yaml
80 changes: 75 additions & 5 deletions kustomize/overlays/uat/deployment_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ spec:
secretKeyRef:
name: healthcheck-env-uat
key: CSW_API
- name: DBCA_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_GOING_BUSHFIRES_URL
- name: KMI_URL
valueFrom:
secretKeyRef:
Expand All @@ -57,3 +52,78 @@ spec:
secretKeyRef:
name: healthcheck-env-uat
key: TRACKING_POINTS_MAX_DELAY
- name: DBCA_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_GOING_BUSHFIRES_URL
- name: DBCA_CONTROL_LINES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_CONTROL_LINES_URL
- name: DFES_GOING_BUSHFIRES_URL
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DFES_GOING_BUSHFIRES_URL
- name: ALL_CURRENT_HOTSPOTS
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: ALL_CURRENT_HOTSPOTS
- name: LIGHTNING_24H
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: LIGHTNING_24H
- name: LIGHTNING_24_48H
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: LIGHTNING_24_48H
- name: LIGHTNING_48_72H
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: LIGHTNING_48_72H
- name: FUEL_AGE_1_6Y
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: FUEL_AGE_1_6Y
- name: FUEL_AGE_NONFOREST_1_6Y
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: FUEL_AGE_NONFOREST_1_6Y
- name: COG_BASEMAP
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: COG_BASEMAP
- name: STATE_BASEMAP
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: STATE_BASEMAP
- name: DBCA_BURN_PROGRAM
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_BURN_PROGRAM
- name: DAILY_ACTIVE_BURNS
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DAILY_ACTIVE_BURNS
- name: DBCA_LANDS_WATERS
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_LANDS_WATERS
- name: DBCA_LANDS_WATERS_INTEREST
valueFrom:
secretKeyRef:
name: healthcheck-env-uat
key: DBCA_LANDS_WATERS_INTEREST
Loading

0 comments on commit b06f839

Please sign in to comment.