Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
589414e
Bump all dependencies (#234)
nikola-jokic Jul 29, 2025
1e051b8
Update codeowners (#237)
nikola-jokic Jul 29, 2025
878781f
docker: fix readOnly volumes in createContainer (#236)
name-snrl Jul 29, 2025
605551f
Bump @eslint/plugin-kit from 0.3.3 to 0.3.4 (#240)
dependabot[bot] Jul 29, 2025
9a85892
Bump form-data from 4.0.3 to 4.0.4 in /packages/k8s (#239)
dependabot[bot] Jul 29, 2025
9a71a3a
Bump brace-expansion from 1.1.11 to 1.1.12 (#238)
dependabot[bot] Jul 29, 2025
74ce64c
Update codeowners to reflect the same team from the ARC (#251)
nikola-jokic Sep 24, 2025
464be47
Separate CI docker and k8s tests (#250)
nikola-jokic Sep 24, 2025
c67938c
bump actions (#254)
nikola-jokic Oct 2, 2025
96c35e7
Remove dependency on the runner's volume (#244)
nikola-jokic Oct 2, 2025
c03a5fb
Prepare 0.8.0 release and bump dependencies once more (#256)
nikola-jokic Oct 4, 2025
2a289a1
add dockerfile
Goalina Oct 14, 2025
ea25fd1
Change command to remove sudo to fix fs-init inital container (#263)
jlcoo Oct 21, 2025
2934de3
Sort 'find' output before hashing for consistency (#267)
zarko-a Nov 4, 2025
ad9cb43
feat: check if required binaries are present (#272)
vvanouytsel-trendminer Nov 10, 2025
15e8089
Allow non-root container (#264)
nikola-jokic Nov 21, 2025
0951cc7
Improve validation checks after copying (#285)
vvanouytsel Nov 24, 2025
011ffb2
Fix workingDir permissions issue by creating it within init container…
zarko-a Nov 26, 2025
3f829ee
Fix event.json not being copied to /github/workflow in kubernetes-nov…
zarko-a Nov 26, 2025
c101fd3
Merge branch 'actions:main' into feature/wl
Goalina Nov 27, 2025
c3d8e2a
Bump glob from 10.4.5 to 10.5.0 in /packages/docker (#279)
dependabot[bot] Nov 27, 2025
1f60eaf
Bump glob from 10.4.5 to 10.5.0 in /packages/k8s (#278)
dependabot[bot] Nov 27, 2025
4041f86
Bump js-yaml from 4.1.0 to 4.1.1 in /packages/hooklib (#277)
dependabot[bot] Nov 27, 2025
adf5e34
Bump js-yaml from 4.1.0 to 4.1.1 (#276)
dependabot[bot] Nov 27, 2025
652e163
Update Dockerfile to use newer actions-runner version
jlcoo Nov 28, 2025
996cc75
Group dependabot updates (#289)
nikola-jokic Dec 10, 2025
f8e1cae
Reduce the amount of data copied to the workflow pod (#293)
nikola-jokic Dec 10, 2025
5f5708a
Overwrite runnner file commands (#298)
wd-hopkins Dec 12, 2025
d8d2e74
Bump packages (#304)
nikola-jokic Jan 15, 2026
79b6781
fix: delay 30s
tfhddd Jan 28, 2026
81322cd
Merge pull request #9 from ascend-gha-runners/tfh_novolumes
tfhddd Jan 28, 2026
d21e5b4
Prepare 0.8.1 release (#311)
nikola-jokic Feb 4, 2026
720130a
30s
Goalina Feb 10, 2026
6ecda1d
fix: Resolves the issue of inconsistent hash calculations between run…
tfhddd Feb 13, 2026
da9c9de
fix: github连接失败
tfhddd Mar 14, 2026
1bef5a9
Merge pull request #12 from ascend-gha-runners/tfh0314
tfhddd Mar 14, 2026
6da12dd
Bump the all-dependencies group across 1 directory with 6 updates (#327)
dependabot[bot] May 11, 2026
a3e6a4e
Add actions-runtime to CODEOWNERS (#350)
nikola-jokic May 12, 2026
bd7e885
fix(ci): make bootstrap deterministic and align CI installs (#343)
nikola-jokic May 12, 2026
b2f8923
Update Dockerfile
Goalina May 21, 2026
63d2dab
Update Dockerfile
Goalina May 21, 2026
9c3ea5c
Update Dockerfile
Goalina May 21, 2026
ee5c48b
Adding websocket heartbeat (#333)
madAndroid May 27, 2026
3e71032
Bump the all-dependencies group across 1 directory with 6 updates (#363)
dependabot[bot] May 27, 2026
bcd95ae
Fix error serialization in 4 catch blocks where `JSON.stringify(error…
jeanschmidt Jun 3, 2026
af73fee
Resolve service name conflicts when the name is computed to the same …
nikola-jokic Jun 4, 2026
0eda272
Bump the all-dependencies group across 1 directory with 7 updates (#360)
dependabot[bot] Jun 4, 2026
d170a93
fix(k8s): prevent circular-JSON crash in catch-block debug logs (#364)
remidebette Jun 5, 2026
721a06a
Fix misleading error/debug messages in run-container-step.ts (#370)
Copilot Jun 5, 2026
cf62bcc
Bump the all-dependencies group across 1 directory with 5 updates (#388)
dependabot[bot] Jun 24, 2026
da1044a
feat: surface unrecoverable container errors during pod wait
Longwt123 Jun 22, 2026
58f99dd
feat: add comprehensive pod failure diagnostics and configurable erro…
Longwt123 Jun 25, 2026
79aeb19
style: fix prettier 2.6.2 formatting in index.ts
Longwt123 Jun 25, 2026
893606e
fix: upgrade actions-runner base image to 2.335.1
Longwt123 Jun 26, 2026
820f097
fix: add namespace() in-cluster fallback and amd64 platform flag
Longwt123 Jun 26, 2026
a56d0b6
fix: update listNamespacedEvent to new k8s client API style
Longwt123 Jun 26, 2026
1257123
fix: revert runner base image to match release/no_volumes (2.334.0)
Longwt123 Jun 27, 2026
8071664
fix: deduplicate and clean up pod failure error output
Longwt123 Jun 27, 2026
1bb105f
feat: improve pod failure error output formatting
Longwt123 Jun 27, 2026
bbb2d33
fix: clean up error layering and stray gitignore entry
Longwt123 Jun 27, 2026
974ae50
feat: detect unrecoverable pod event errors for fast-fail
Longwt123 Jun 27, 2026
6c58886
fix: extract k8s API message from raw HttpException for pod create er…
Longwt123 Jun 27, 2026
9045356
fix: remove regex 's' flag incompatible with pre-ES2018 tsconfig target
Longwt123 Jun 27, 2026
75aaa7e
fix: reliably extract k8s API error message from HttpException body
Longwt123 Jun 27, 2026
574910c
fix: use lastIndexOf to find Body boundary before Headers line
Longwt123 Jun 27, 2026
3d1ad69
feat: add condition-based fast-fail as RBAC-free fallback for schedul…
Longwt123 Jun 29, 2026
3740490
fix: always run condition-based fast-fail, not only when events are e…
Longwt123 Jun 29, 2026
20e2ef2
chore: bump js-yaml to 4.2.0 and uuid to 11.1.1, clean up jest setup …
Longwt123 Jun 30, 2026
b9cff6a
补充修改版本,解决安全漏洞问题
Longwt123 Jun 30, 2026
b5e0a2e
refactor: move utils.ts to utils/index.ts for coverage gate compatibi…
Longwt123 Jun 30, 2026
34a8889
refactor: address review comments on coverage config
Longwt123 Jun 30, 2026
97a7456
chore(deps): 更新 uuid 依賴至 ^11.1.1
Longwt123 Jun 30, 2026
c031442
chore(deps): 更新 uuid 依赖至 11.1.1 版本
Longwt123 Jun 30, 2026
978b289
test: add comprehensive utils unit tests for k8s, docker, and hooklib
Longwt123 Jun 30, 2026
d050ac0
test: add vitest-compatible spec files for utils coverage gate
Longwt123 Jun 30, 2026
c4c1329
fix(test): correct invalid working directory test case for writeConta…
Longwt123 Jun 30, 2026
ecc4039
chore: revert unnecessary changes, keep only utils rename and spec files
Longwt123 Jul 1, 2026
eb902af
chore(docker): 更新 uuid 依赖至版本 11.1.1
Longwt123 Jul 1, 2026
6a5e284
!18 refactor: move utils.ts to utils/index.ts for coverage gate compa…
opensourceways-bot Jul 1, 2026
6c16e5e
feat(runner-container-hooks): expand k8s error detection from Pending…
Longwt123 Jul 1, 2026
27d0097
Merge pull request #20 from opensourceways/issue-1203
flysky22222 Jul 1, 2026
a22a56c
fix: properly unescape k8s API error body for consistent error format
Longwt123 Jul 2, 2026
174736d
!23 fix: properly unescape k8s API error body for consistent error fo…
opensourceways-bot Jul 2, 2026
7f42778
merge: sync with upstream/main and opensourceways/release/no_volumes
Longwt123 Jul 7, 2026
310da6f
fix: address security and robustness review findings
Longwt123 Jul 7, 2026
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
4 changes: 0 additions & 4 deletions .eslintignore

This file was deleted.

56 changes: 0 additions & 56 deletions .eslintrc.json

This file was deleted.

28 changes: 28 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
version: 2

updates:
# Group updates into a single PR per workspace package
- package-ecosystem: npm
directory: "/packages/docker"
schedule:
interval: weekly
groups:
all-dependencies:
patterns:
- "*"
- package-ecosystem: npm
directory: "/packages/hooklib"
schedule:
interval: weekly
groups:
all-dependencies:
patterns:
- "*"
- package-ecosystem: npm
directory: "/packages/k8s"
schedule:
interval: weekly
groups:
all-dependencies:
patterns:
- "*"
69 changes: 59 additions & 10 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,26 +6,75 @@ on:
paths-ignore:
- '**.md'
workflow_dispatch:

jobs:
build:
format-and-lint:
name: Format & Lint Checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sed -i "s|{{PATHTOREPO}}|$(pwd)|" packages/k8s/tests/test-kind.yaml
name: Setup kind cluster yaml config
- uses: helm/kind-action@v1.2.0
- uses: actions/checkout@v5
- uses: actions/setup-node@v6
with:
config: packages/k8s/tests/test-kind.yaml
- run: npm install
node-version: 24
cache: npm
- run: node --version && npm --version
name: Log Node and npm versions
- run: npm ci
name: Install dependencies
- run: npm run bootstrap
name: Bootstrap the packages
- run: npm run build-all
name: Build packages
- run: npm run format-check
name: Check formatting
- name: Check linter
run: |
npm run lint
git diff --exit-code -- ':!packages/k8s/tests/test-kind.yaml'
- name: Run tests
run: npm run test
git diff --exit-code -- . ':!packages/k8s/tests/test-kind.yaml'

docker-tests:
name: Docker Hook Tests
runs-on: ubuntu-latest
needs: format-and-lint
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v6
with:
node-version: 24
cache: npm
- run: node --version && npm --version
name: Log Node and npm versions
- run: npm ci
name: Install dependencies
- run: npm run bootstrap
name: Bootstrap the packages
- run: npm run build-all
name: Build packages
- name: Run Docker tests
run: npm run test --prefix packages/docker

k8s-tests:
name: Kubernetes Hook Tests
runs-on: ubuntu-latest
needs: format-and-lint
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v6
with:
node-version: 24
cache: npm
- run: sed -i "s|{{PATHTOREPO}}|$(pwd)|" packages/k8s/tests/test-kind.yaml
name: Setup kind cluster yaml config
- uses: helm/kind-action@v1.12.0
with:
config: packages/k8s/tests/test-kind.yaml
- run: node --version && npm --version
name: Log Node and npm versions
- run: npm ci
name: Install dependencies
- run: npm run bootstrap
name: Bootstrap the packages
- run: npm run build-all
name: Build packages
- name: Run Kubernetes tests
run: npm run test --prefix packages/k8s
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v5

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,12 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5

- uses: actions/setup-node@v6
with:
node-version: 24
cache: npm
- name: Install dependencies
run: npm install

Expand All @@ -21,7 +25,7 @@ jobs:
- name: Build packages
run: npm run build-all

- uses: actions/github-script@v7
- uses: actions/github-script@v8
id: releaseVersion
with:
result-encoding: string
Expand All @@ -47,7 +51,7 @@ jobs:

- name: Create release notes
id: releaseNotes
uses: actions/github-script@v7
uses: actions/github-script@v8
with:
script: |
const fs = require('fs');
Expand Down
2 changes: 1 addition & 1 deletion CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* @actions/actions-launch
* @github/actions-runtime @nikola-jokic
14 changes: 14 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
FROM swr.cn-north-4.myhuaweicloud.com/opensourceway/node:latest AS runner_builder

WORKDIR /app

COPY . /app/

RUN npm install && npm run bootstrap && npm run build-all

FROM ghcr.io/actions/actions-runner:2.334.0

COPY --from=runner_builder /app/packages/k8s/dist/index.js /home/runner/k8s/index.js

USER runner

122 changes: 122 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
const eslint = require('@eslint/js');
const tseslint = require('@typescript-eslint/eslint-plugin');
const tsparser = require('@typescript-eslint/parser');
const globals = require('globals');
const pluginJest = require('eslint-plugin-jest');

module.exports = [
eslint.configs.recommended,
{
files: ['**/*.ts'],
languageOptions: {
parser: tsparser,
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module',
project: ['./tsconfig.json', './packages/*/tsconfig.json']
},
globals: {
...globals.node,
...globals.es6
}
},
plugins: {
'@typescript-eslint': tseslint,
},
rules: {
// Disabled rules from original config
'eslint-comments/no-use': 'off',
'import/no-namespace': 'off',
'no-constant-condition': 'off',
'no-unused-vars': 'off',
'i18n-text/no-en': 'off',
'camelcase': 'off',
'semi': 'off',
'no-shadow': 'off',

// TypeScript ESLint rules
'@typescript-eslint/no-unused-vars': 'error',
'@typescript-eslint/explicit-member-accessibility': ['error', { accessibility: 'no-public' }],
'@typescript-eslint/no-require-imports': 'error',
'@typescript-eslint/array-type': 'error',
'@typescript-eslint/await-thenable': 'error',
'@typescript-eslint/explicit-function-return-type': ['error', { allowExpressions: true }],
'@typescript-eslint/no-array-constructor': 'error',
'@typescript-eslint/no-empty-interface': 'error',
'@typescript-eslint/no-explicit-any': 'off', // Fixed: removed duplicate and kept only this one
'@typescript-eslint/no-extraneous-class': 'error',
'@typescript-eslint/no-floating-promises': 'error',
'@typescript-eslint/no-for-in-array': 'error',
'@typescript-eslint/no-inferrable-types': 'error',
'@typescript-eslint/no-misused-new': 'error',
'@typescript-eslint/no-namespace': 'error',
'@typescript-eslint/no-non-null-assertion': 'warn',
'@typescript-eslint/no-unnecessary-qualifier': 'error',
'@typescript-eslint/no-unnecessary-type-assertion': 'error',
'@typescript-eslint/no-useless-constructor': 'error',
'@typescript-eslint/no-var-requires': 'error',
'@typescript-eslint/prefer-for-of': 'warn',
'@typescript-eslint/prefer-function-type': 'warn',
'@typescript-eslint/prefer-includes': 'error',
'@typescript-eslint/prefer-string-starts-ends-with': 'error',
'@typescript-eslint/promise-function-async': 'error',
'@typescript-eslint/require-array-sort-compare': 'error',
'@typescript-eslint/restrict-plus-operands': 'error',
'@typescript-eslint/unbound-method': 'error',
'@typescript-eslint/no-shadow': ['error']
}
},
{
// Test files configuration - Fixed file pattern to match .ts files
files: ['**/*test*.ts', '**/*spec*.ts', '**/tests/**/*.ts'],
languageOptions: {
parser: tsparser,
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module',
project: ['./tsconfig.json', './packages/*/tsconfig.json']
},
globals: {
...globals.node,
...globals.es6,
// Fixed Jest globals
describe: 'readonly',
it: 'readonly',
test: 'readonly',
expect: 'readonly',
beforeEach: 'readonly',
afterEach: 'readonly',
beforeAll: 'readonly',
afterAll: 'readonly',
jest: 'readonly'
}
},
plugins: {
'@typescript-eslint': tseslint,
jest: pluginJest
},
rules: {
// Disable no-undef for test files since Jest globals are handled above
'no-undef': 'off',
// Relax some rules for test files
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/explicit-function-return-type': 'off'
}
},
{
files: ['**/jest.config.js', '**/jest.setup.js'],
languageOptions: {
globals: {
...globals.node,
jest: 'readonly',
module: 'writable'
}
},
rules: {
'@typescript-eslint/no-require-imports': 'off',
'@typescript-eslint/no-var-requires': 'off',
'import/no-commonjs': 'off'
}
}
];
3 changes: 0 additions & 3 deletions examples/extension.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ metadata:
labels:
labeled-by: "extension"
spec:
securityContext:
runAsUser: 1000
runAsGroup: 3000
restartPolicy: Never
containers:
- name: $job # overwrites job container
Expand Down
Loading