@flowfuse/driver-docker 2.25.0 → 2.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ # Trivy ignore file
2
+ # Add patterns to ignore specific vulnerabilities
@@ -0,0 +1,29 @@
1
+ # Trivy Security Scanner Configuration
2
+ # Documentation: https://aquasecurity.github.io/trivy/latest/docs/configuration/
3
+
4
+ scan:
5
+ scanners:
6
+ - vuln
7
+ - secret
8
+
9
+ skip-dirs:
10
+ - node_modules
11
+ - .git
12
+ - coverage
13
+ - ci
14
+
15
+ severity:
16
+ - CRITICAL
17
+ - HIGH
18
+ - MEDIUM
19
+ - LOW
20
+
21
+ pkg:
22
+ types:
23
+ - os
24
+ - library
25
+ include-dev-deps: true
26
+
27
+ format: "sarif"
28
+ ignorefile: ".github/.trivyignore.yaml"
29
+ exit-code: 0
@@ -13,9 +13,9 @@ jobs:
13
13
  matrix:
14
14
  node-version: [20]
15
15
  steps:
16
- - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
16
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
17
17
  - name: Use Node.js ${{ matrix.node-version }}
18
- uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
18
+ uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
19
19
  with:
20
20
  node-version: ${{ matrix.node-version }}
21
21
  - name: Install Dependencies
@@ -8,11 +8,11 @@ jobs:
8
8
  publish:
9
9
  runs-on: ubuntu-latest
10
10
  steps:
11
- - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
12
- - uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
11
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
12
+ - uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
13
13
  with:
14
14
  node-version: 18
15
15
  - run: npm ci --omit dev
16
- - uses: JS-DevTools/npm-publish@7f8fe47b3bea1be0c3aec2b717c5ec1f3e03410b # v4.1.1
16
+ - uses: JS-DevTools/npm-publish@4ce4bd0f334d5316473155078da1955d42148494 # v4.1.4
17
17
  with:
18
18
  token: ${{ secrets.NPM_PUBLISH_TOKEN }}
@@ -0,0 +1,19 @@
1
+ name: SAST Scan
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+ workflow_dispatch:
11
+
12
+ concurrency:
13
+ group: ${{ github.workflow }}-${{ github.ref }}
14
+ cancel-in-progress: true
15
+
16
+ jobs:
17
+ scan:
18
+ name: SAST Scan
19
+ uses : flowfuse/github-actions-workflows/.github/workflows/sast_scan.yaml@v0.47.0
package/CHANGELOG.md CHANGED
@@ -1,3 +1,18 @@
1
+ #### 2.26.1: Release
2
+
3
+ - Bump JS-DevTools/npm-publish from 4.1.3 to 4.1.4 (#179)
4
+ - Bump flowfuse/github-actions-workflows/.github/workflows/sast_scan.yaml (#181)
5
+ - Bump actions/checkout from 6.0.1 to 6.0.2 (#182)
6
+ - Bump actions/setup-node from 6.1.0 to 6.2.0 (#180)
7
+ - ci: Enable SAST (#177) @ppawlowski
8
+
9
+ #### 2.26.0: Release
10
+
11
+ - Bump JS-DevTools/npm-publish from 4.1.2 to 4.1.3 (#176)
12
+ - Bump JS-DevTools/npm-publish from 4.1.1 to 4.1.2 (#174) @app/dependabot
13
+ - fix eqeqeq & quotes (#175) @hardillb
14
+ - Convert to eslint v9 (#173) @hardillb
15
+
1
16
  #### 2.25.0: Release
2
17
 
3
18
 
package/docker.js CHANGED
@@ -357,7 +357,7 @@ module.exports = {
357
357
  container = undefined
358
358
  }
359
359
  } catch (err) {
360
- console.log(err)
360
+ console.error(err)
361
361
  }
362
362
  if (container) {
363
363
  const state = await container.inspect()
@@ -420,7 +420,7 @@ module.exports = {
420
420
  createMQttTopicAgent(broker)
421
421
  }
422
422
  } catch (err) {
423
- console.log(err)
423
+ console.error(err)
424
424
  }
425
425
  }
426
426
  }
@@ -749,7 +749,7 @@ module.exports = {
749
749
  await container.stop()
750
750
  await container.remove()
751
751
  } catch (err) {
752
- console.log(err)
752
+ console.error(err)
753
753
  }
754
754
  },
755
755
  getBrokerAgentState: async (broker) => {
@@ -0,0 +1,56 @@
1
+ import globals from 'globals'
2
+ import js from '@eslint/js'
3
+ import neostandard, { resolveIgnoresFromGitignore } from 'neostandard'
4
+ import stylistic from '@stylistic/eslint-plugin'
5
+ import noOnlyTests from 'eslint-plugin-no-only-tests'
6
+
7
+ export default [
8
+ {
9
+ files: ['**/*.js'],
10
+ languageOptions: {
11
+ globals: {
12
+ ...globals.browser
13
+ },
14
+ sourceType: 'script'
15
+ }
16
+ },
17
+ {
18
+ files: ['test/**/*.js'],
19
+ languageOptions: {
20
+ globals: {
21
+ ...globals.browser,
22
+ ...globals.mocha
23
+ },
24
+ sourceType: 'script'
25
+ }
26
+ },
27
+ {
28
+ ignores: [
29
+ ...resolveIgnoresFromGitignore()
30
+ ]
31
+ },
32
+ js.configs.recommended,
33
+ ...neostandard(),
34
+ {
35
+ plugins: {
36
+ '@stylistic': stylistic,
37
+ 'no-only-tests': noOnlyTests
38
+ },
39
+ rules: {
40
+ // built-in
41
+ eqeqeq: 'error',
42
+ 'object-shorthand': ['error'],
43
+ 'no-console': ['error', { allow: ['debug', 'info', 'warn', 'error'] }],
44
+ quotes: ['off', 'error', 'single', { avoidEscape: true }],
45
+
46
+ // plugin:stylistic
47
+ '@stylistic/indent': ['warn', 4], // https://eslint.style/rules/indent#options
48
+ '@stylistic/spaced-comment': ['error', 'always'], // https://eslint.style/rules/spaced-comment
49
+ '@stylistic/no-multi-spaces': 'error', // https://eslint.style/rules/no-multi-spaces#no-multi-spaces
50
+ '@stylistic/comma-dangle': ['error', 'never'], // https://eslint.style/rules/comma-dangle#comma-dangle
51
+
52
+ // plugin:no-only-tests
53
+ 'no-only-tests/no-only-tests': 'error'
54
+ }
55
+ }
56
+ ]
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@flowfuse/driver-docker",
3
- "version": "2.25.0",
3
+ "version": "2.26.1",
4
4
  "description": "Docker driver for FlowFuse",
5
5
  "main": "docker.js",
6
6
  "scripts": {
7
7
  "test": "echo \"Error: no test specified\" && exit 1",
8
- "lint": "eslint -c .eslintrc \"*.js\"",
9
- "lint:fix": "eslint -c .eslintrc \"*.js\" --fix"
8
+ "lint": "eslint -c eslint.config.mjs",
9
+ "lint:fix": "eslint -c eslint.config.mjs --fix"
10
10
  },
11
11
  "repository": {
12
12
  "type": "git",
@@ -26,7 +26,10 @@
26
26
  "got": "^11.8.0"
27
27
  },
28
28
  "devDependencies": {
29
- "eslint": "^8.25.0",
30
- "eslint-config-standard": "^17.0.0"
29
+ "@eslint/js": "^9.39.2",
30
+ "eslint": "^9.39.2",
31
+ "eslint-plugin-no-only-tests": "^3.3.0",
32
+ "globals": "^16.5.0",
33
+ "neostandard": "^0.12.2"
31
34
  }
32
35
  }
package/.eslintrc DELETED
@@ -1,19 +0,0 @@
1
- {
2
- "root": true,
3
- "env": {
4
- "browser": true,
5
- "commonjs": true,
6
- "es2021": true,
7
- "mocha": true
8
- },
9
- "extends": [
10
- "standard"
11
- ],
12
- "parserOptions": {
13
- "ecmaVersion": 12
14
- },
15
- "rules": {
16
- "indent": ["error", 4],
17
- "object-shorthand": ["error"]
18
- }
19
- }