Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
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
7 changes: 4 additions & 3 deletions .github/workflows/develop-func-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ name: CI_AutoMerge_Dependabot

on:
pull_request:
paths-ignore: # https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
paths-ignore:
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
- "**/README.md"
- "**/dependabot.yml"
- ".github/workflows/prod-func-ci.yml"
Expand All @@ -27,7 +28,7 @@ jobs:
build:
uses: IATI/.github/.github/workflows/build_node_save.yaml@main
with:
npm_version: ^10
npm_version: ^11
save_artifact: false

automerge:
Expand All @@ -37,6 +38,6 @@ jobs:
pull-requests: write
contents: write
steps:
- uses: fastify/github-action-merge-dependabot@v3.11
- uses: fastify/github-action-merge-dependabot@v3.12
with:
github-token: ${{secrets.GITHUB_TOKEN}}
13 changes: 7 additions & 6 deletions .github/workflows/develop-func-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ name: Deploy_To_Dev_Function_On_Push
on:
workflow_dispatch: # Allow Manual Run from GitHub
push:
paths-ignore: # https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
paths-ignore:
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
- "**/README.md" # don't run on README.md file updates anywhere in repo
- "**/dependabot.yml"
- ".github/workflows/prod-func-ci.yml"
Expand Down Expand Up @@ -47,7 +48,7 @@ jobs:
if: ${{ needs.should_run.outputs.should_run == 'true' }}
uses: IATI/.github/.github/workflows/build_node_save.yaml@main
with:
npm_version: ^10
npm_version: ^11
save_artifact: true
artifact_name: build-artifact-dev

Expand All @@ -56,7 +57,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Download build artifact
uses: actions/download-artifact@v7
uses: actions/download-artifact@v8
with:
name: build-artifact-dev

Expand All @@ -66,7 +67,7 @@ jobs:
rm build-artifact-dev.zip

- name: "Login via Azure CLI"
uses: azure/login@v2.3.0
uses: azure/login@v3.0.0
with:
creds: ${{ env.AZURE_CREDENTIALS }} # Service Principal credentials saved in GitHub Secrets

Expand Down Expand Up @@ -126,7 +127,7 @@ jobs:
"value": "${{ env.VALIDATOR_FUNC_KEY }}",
"slotSetting": false
},
{
{
"name": "AzureWebJobsSecretStorageType",
"value": "keyvault",
"slotSetting": false
Expand Down Expand Up @@ -164,7 +165,7 @@ jobs:
]

- name: "Run Azure Functions Action"
uses: Azure/[email protected].3
uses: Azure/[email protected].6
with:
app-name: func-${{ env.NAME }}-${{ env.STAGE }}

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/prod-func-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
build_save:
uses: IATI/.github/.github/workflows/build_node_save.yaml@main
with:
npm_version: ^10
npm_version: ^11
save_artifact: true
artifact_name: build-artifact-prod

Expand All @@ -43,7 +43,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Download build artifact
uses: actions/download-artifact@v7
uses: actions/download-artifact@v8
with:
name: build-artifact-prod

Expand All @@ -53,7 +53,7 @@ jobs:
rm build-artifact-prod.zip

- name: "Login via Azure CLI"
uses: azure/login@v2.3.0
uses: azure/login@v3.0.0
with:
creds: ${{ env.AZURE_CREDENTIALS }} # Service Principal credentials saved in GitHub Secrets

Expand Down Expand Up @@ -151,7 +151,7 @@ jobs:
]

- name: "Run Azure Functions Action"
uses: Azure/[email protected].3
uses: Azure/[email protected].6
with:
app-name: func-${{ env.NAME }}-${{ env.STAGE }}

Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
lts/iron
lts/krypton
5 changes: 1 addition & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,10 @@ See OpenAPI specification `postman/schemas/index.yaml`. To view locally in Swagg
#### blob-trigger-adhoc-file

- Blob Trigger

- When file is added to blob storage container with name `ADHOC_CONTAINER`, this Function is triggered.
- `/api/pvt/adhoc/upload` or `/api/pvt/adhoc/url` are the endpoints used to add files to blob storage.

- Actions

- Sends file to Validator API
- Saves validation report and metadata to `adhoc_validation` table

Expand Down Expand Up @@ -155,7 +153,7 @@ It would be better to spin up a dedicate test environment on Github using docker

#### Against a local instance of `validator-services`

If you want to test against a local instance of `validator-services` you need to have it pointed to a Unified Pipeline database and an Azure storage account.
If you want to run the tests against a local instance of `validator-services` you need to have your locally running version of `validator-services` pointed to a Unified Pipeline database and an Azure storage account. You can do this using the [Unified Data Platform Local Dev](https://github.com/IATI/unified-data-platform-local-dev) setup.

If you use a local database, you will need to ensure that you have run the Pipeline refresher with a reasonable number of datasets through to the validate stage, because the tests search for a dataset which has warnings, to check various things.

Expand All @@ -180,7 +178,6 @@ To run against production, use `integration-tests/envs/validator-services-direct
### Modifying/Adding Tets

1. Check the tests in Postman are in sync with the Github repo:

- Export the `validator-services` collection from the Postman client to `./integration-tests`
- Run `npm run format`
- Run `git diff integration-tests/validator-services-tests.postman_collection.json`
Expand Down
4 changes: 2 additions & 2 deletions blob-trigger-adhoc-file/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ import {

export default async function blobTriggerAdhocFile(context) {
let errorStatus = null;
let result = null;
let result;
let valid = null;
let report = null;
let report;

try {
if (isInMaintenanceMode(maintenanceModes.NO_WRITE)) {
Expand Down
2 changes: 1 addition & 1 deletion host.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
},
"extensionBundle": {
"id": "Microsoft.Azure.Functions.ExtensionBundle",
"version": "[2.*, 3.0.0)"
"version": "[4.0.0, 5.0.0)"
}
}
Loading
Loading