Compare commits

...

10 Commits

Author SHA1 Message Date
gitea-actions fce2468b2b chore: bump version [skip ci] 2026-06-05 21:25:12 +00:00
deac 30ff44c33b Merge branch 'main' of ssh://gitea.pixelparasol.com:4122/pixel-parasol-public/gitea-actions
/ publish (push) Successful in 7s
2026-06-05 17:24:54 -04:00
deac 11fd063f95 allow skip build artifact for node action 2026-06-05 17:24:49 -04:00
gitea-actions 70758f1d74 chore: bump version [skip ci] 2026-06-05 20:44:36 +00:00
deac 395bf58622 add additional args to test npm runs
/ publish (push) Successful in 7s
2026-06-05 16:44:27 -04:00
gitea-actions 358bf3b06f chore: bump version [skip ci] 2026-06-01 00:51:33 +00:00
deac 298834cd9f fix: remove kubeconfig cleanup from template and diff — kubeconfig must persist across pipeline steps
/ publish (push) Failing after 6s
2026-06-01 00:51:27 +00:00
deac a6dc98df0d fix: remove kubeconfig cleanup from template and diff — kubeconfig must persist across pipeline steps
/ publish (push) Successful in 7s
2026-06-01 00:51:26 +00:00
gitea-actions 04d506533e chore: bump version [skip ci] 2026-06-01 00:46:17 +00:00
deac a8797ceedb revert: restore base64 -d in kubectl/configure (fetch-secret outputs base64)
/ publish (push) Successful in 7s
2026-06-01 00:46:10 +00:00
8 changed files with 22 additions and 14 deletions
+1 -1
View File
@@ -1 +1 @@
1.12.0 1.16.0
-5
View File
@@ -73,8 +73,3 @@ runs:
fi fi
helm dependency update "$CHART_PATH" helm dependency update "$CHART_PATH"
helm diff upgrade "$DEPLOYMENT_NAME" "$CHART_PATH" -n "$NAMESPACE" --values "$VALUES_FILE" $SET_FLAGS --context 5 helm diff upgrade "$DEPLOYMENT_NAME" "$CHART_PATH" -n "$NAMESPACE" --values "$VALUES_FILE" $SET_FLAGS --context 5
- name: Remove kubeconfig
if: always()
shell: sh
run: rm -f ~/.kube/config
-5
View File
@@ -68,8 +68,3 @@ runs:
fi fi
helm dependency update "$CHART_PATH" helm dependency update "$CHART_PATH"
helm template "$DEPLOYMENT_NAME" "$CHART_PATH" -n "$NAMESPACE" --values "$VALUES_FILE" $SET_FLAGS helm template "$DEPLOYMENT_NAME" "$CHART_PATH" -n "$NAMESPACE" --values "$VALUES_FILE" $SET_FLAGS
- name: Remove kubeconfig
if: always()
shell: sh
run: rm -f ~/.kube/config
+2 -2
View File
@@ -2,7 +2,7 @@ name: Configure Kubectl
description: Configure kubectl for use with Kubernetes description: Configure kubectl for use with Kubernetes
inputs: inputs:
K8S_CONFIG: K8S_CONFIG:
description: "The Kubernetes config (plain YAML)" description: "The base64-encoded Kubernetes config"
required: true required: true
K8S_NAMESPACE: K8S_NAMESPACE:
description: "The K8S namespace" description: "The K8S namespace"
@@ -28,7 +28,7 @@ runs:
echo "Configuring kubectl for context=${{ inputs.K8S_CONTEXT }} namespace=${{ inputs.K8S_NAMESPACE }}" echo "Configuring kubectl for context=${{ inputs.K8S_CONTEXT }} namespace=${{ inputs.K8S_NAMESPACE }}"
rm -f ~/.kube/config rm -f ~/.kube/config
mkdir -p ~/.kube mkdir -p ~/.kube
printf '%s' "$K8S_CONFIG" > ~/.kube/config printf '%s' "$K8S_CONFIG" | base64 -d > ~/.kube/config
kubectl config set-context ${{ inputs.K8S_CONTEXT }} --cluster=${{ inputs.K8S_CONTEXT }} --namespace=${{ inputs.K8S_NAMESPACE }} kubectl config set-context ${{ inputs.K8S_CONTEXT }} --cluster=${{ inputs.K8S_CONTEXT }} --namespace=${{ inputs.K8S_NAMESPACE }}
kubectl config use-context ${{ inputs.K8S_CONTEXT }} kubectl config use-context ${{ inputs.K8S_CONTEXT }}
echo "kubectl configured successfully" echo "kubectl configured successfully"
+1
View File
@@ -18,6 +18,7 @@ Install dependencies, build, and upload a build artifact
| `ARTIFACT_PATH` | <p>Path to upload as the artifact</p> | `false` | `dist` | | `ARTIFACT_PATH` | <p>Path to upload as the artifact</p> | `false` | `dist` |
| `COPY_PRISMA_ENGINE` | <p>Copy the Prisma query engine binaries into the build directory</p> | `false` | `false` | | `COPY_PRISMA_ENGINE` | <p>Copy the Prisma query engine binaries into the build directory</p> | `false` | `false` |
| `WORKING_DIRECTORY` | <p>Working directory for install, build, and artifact steps</p> | `false` | `.` | | `WORKING_DIRECTORY` | <p>Working directory for install, build, and artifact steps</p> | `false` | `.` |
| `UPLOAD_ARTIFACT` | <p>Whether to upload the build artifact</p> | `false` | `true` |
<!-- action-docs-inputs source="action.yml" --> <!-- action-docs-inputs source="action.yml" -->
<!-- action-docs-runs source="action.yml" --> <!-- action-docs-runs source="action.yml" -->
+4
View File
@@ -22,6 +22,9 @@ inputs:
WORKING_DIRECTORY: WORKING_DIRECTORY:
description: "Working directory for install, build, and artifact steps" description: "Working directory for install, build, and artifact steps"
default: "." default: "."
UPLOAD_ARTIFACT:
description: "Whether to upload the build artifact"
default: "true"
runs: runs:
using: composite using: composite
@@ -56,6 +59,7 @@ runs:
cp node_modules/.prisma/client/libquery_engine-* build/prisma/ cp node_modules/.prisma/client/libquery_engine-* build/prisma/
- name: Upload Build Artifact - name: Upload Build Artifact
if: inputs.UPLOAD_ARTIFACT != 'false'
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3
with: with:
name: ${{ inputs.ARTIFACT_NAME }} name: ${{ inputs.ARTIFACT_NAME }}
+10
View File
@@ -8,6 +8,7 @@ Composite action: install dependencies and run an npm test script.
|---|---|---| |---|---|---|
| `INSTALL_CMD` | Install command | `npm ci` | | `INSTALL_CMD` | Install command | `npm ci` |
| `TEST_SCRIPT` | npm script to run (must exist in `package.json`) | `test` | | `TEST_SCRIPT` | npm script to run (must exist in `package.json`) | `test` |
| `TEST_ARGS` | Additional arguments passed after `--` to the test script | `` |
| `WORKING_DIRECTORY` | Directory to run commands in | `.` | | `WORKING_DIRECTORY` | Directory to run commands in | `.` |
## Usage ## Usage
@@ -18,6 +19,15 @@ Composite action: install dependencies and run an npm test script.
TEST_SCRIPT: test:unit TEST_SCRIPT: test:unit
``` ```
With extra args:
```yaml
- uses: stat-tackler/stat-tackler-infra/test/npm@main
with:
TEST_SCRIPT: test:coverage
TEST_ARGS: --silent --reporter=dot --test-timeout=30000
```
### Common test scripts by project ### Common test scripts by project
| Project | Script | Runner | | Project | Script | Runner |
+4 -1
View File
@@ -8,6 +8,9 @@ inputs:
TEST_SCRIPT: TEST_SCRIPT:
description: "npm script to run (must exist in package.json)" description: "npm script to run (must exist in package.json)"
default: "test" default: "test"
TEST_ARGS:
description: "Additional arguments to pass after -- to the test script"
default: ""
WORKING_DIRECTORY: WORKING_DIRECTORY:
description: "Directory to run commands in" description: "Directory to run commands in"
default: "." default: "."
@@ -37,4 +40,4 @@ runs:
- name: Test - name: Test
shell: sh shell: sh
working-directory: ${{ inputs.WORKING_DIRECTORY }} working-directory: ${{ inputs.WORKING_DIRECTORY }}
run: npm run ${{ inputs.TEST_SCRIPT }} run: npm run ${{ inputs.TEST_SCRIPT }}${{ inputs.TEST_ARGS != '' && format(' -- {0}', inputs.TEST_ARGS) || '' }}