-
Notifications
You must be signed in to change notification settings - Fork 241
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvement/cldsrv 553 bump deps #5711
base: development/9.0
Are you sure you want to change the base?
Changes from all commits
7bfe32a
48b4a6a
8e6a32f
a942098
5b2d51c
1f72d50
6522b62
b60f93f
f1fdb1c
f03db55
f1a4f29
7fb46f3
bc7b54f
f92e7e3
43ba749
06b308c
0443802
d608869
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -77,7 +77,7 @@ jobs: | |||||||||
uses: actions/checkout@v4 | ||||||||||
- uses: actions/setup-node@v4 | ||||||||||
with: | ||||||||||
node-version: '16' | ||||||||||
node-version: '22' | ||||||||||
cache: yarn | ||||||||||
- name: install typescript | ||||||||||
shell: bash | ||||||||||
|
@@ -106,7 +106,7 @@ jobs: | |||||||||
uses: actions/checkout@v4 | ||||||||||
- uses: actions/setup-node@v4 | ||||||||||
with: | ||||||||||
node-version: '16' | ||||||||||
node-version: '22' | ||||||||||
cache: yarn | ||||||||||
- name: install typescript | ||||||||||
shell: bash | ||||||||||
|
@@ -149,7 +149,7 @@ jobs: | |||||||||
if: always() | ||||||||||
|
||||||||||
build: | ||||||||||
runs-on: ubuntu-20.04 | ||||||||||
runs-on: ubuntu-latest | ||||||||||
permissions: | ||||||||||
contents: read | ||||||||||
packages: write | ||||||||||
|
@@ -361,38 +361,38 @@ jobs: | |||||||||
source: /tmp/artifacts | ||||||||||
if: always() | ||||||||||
|
||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should be skipped instead of removed:
Suggested change
|
||||||||||
utapi-v2-tests: | ||||||||||
runs-on: ubuntu-latest | ||||||||||
needs: build | ||||||||||
env: | ||||||||||
ENABLE_UTAPI_V2: t | ||||||||||
S3BACKEND: mem | ||||||||||
BUCKET_DENY_FILTER: utapi-event-filter-deny-bucket | ||||||||||
CLOUDSERVER_IMAGE: ghcr.io/${{ github.repository }}:${{ github.sha }} | ||||||||||
MONGODB_IMAGE: ghcr.io/${{ github.repository }}/ci-mongodb:${{ github.sha }} | ||||||||||
JOB_NAME: ${{ github.job }} | ||||||||||
steps: | ||||||||||
- name: Checkout | ||||||||||
uses: actions/checkout@v4 | ||||||||||
- name: Setup CI environment | ||||||||||
uses: ./.github/actions/setup-ci | ||||||||||
- name: Setup CI services | ||||||||||
run: docker compose up -d | ||||||||||
working-directory: .github/docker | ||||||||||
- name: Run file utapi v2 tests | ||||||||||
run: |- | ||||||||||
set -ex -o pipefail; | ||||||||||
bash wait_for_local_port.bash 8000 40 | ||||||||||
yarn run test_utapi_v2 | tee /tmp/artifacts/${{ github.job }}/tests.log | ||||||||||
- name: Upload logs to artifacts | ||||||||||
uses: scality/action-artifacts@v4 | ||||||||||
with: | ||||||||||
method: upload | ||||||||||
url: https://artifacts.scality.net | ||||||||||
user: ${{ secrets.ARTIFACTS_USER }} | ||||||||||
password: ${{ secrets.ARTIFACTS_PASSWORD }} | ||||||||||
source: /tmp/artifacts | ||||||||||
if: always() | ||||||||||
# utapi-v2-tests: | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. better to skip the job than to comment it:
Suggested change
|
||||||||||
# runs-on: ubuntu-latest | ||||||||||
# needs: build | ||||||||||
# env: | ||||||||||
# ENABLE_UTAPI_V2: t | ||||||||||
# S3BACKEND: mem | ||||||||||
# BUCKET_DENY_FILTER: utapi-event-filter-deny-bucket | ||||||||||
# CLOUDSERVER_IMAGE: ghcr.io/${{ github.repository }}:${{ github.sha }} | ||||||||||
# MONGODB_IMAGE: ghcr.io/${{ github.repository }}/ci-mongodb:${{ github.sha }} | ||||||||||
# JOB_NAME: ${{ github.job }} | ||||||||||
# steps: | ||||||||||
# - name: Checkout | ||||||||||
# uses: actions/checkout@v4 | ||||||||||
# - name: Setup CI environment | ||||||||||
# uses: ./.github/actions/setup-ci | ||||||||||
# - name: Setup CI services | ||||||||||
# run: docker compose up -d | ||||||||||
# working-directory: .github/docker | ||||||||||
# - name: Run file utapi v2 tests | ||||||||||
# run: |- | ||||||||||
# set -ex -o pipefail; | ||||||||||
# bash wait_for_local_port.bash 8000 40 | ||||||||||
# yarn run test_utapi_v2 | tee /tmp/artifacts/${{ github.job }}/tests.log | ||||||||||
# - name: Upload logs to artifacts | ||||||||||
# uses: scality/action-artifacts@v4 | ||||||||||
# with: | ||||||||||
# method: upload | ||||||||||
# url: https://artifacts.scality.net | ||||||||||
# user: ${{ secrets.ARTIFACTS_USER }} | ||||||||||
# password: ${{ secrets.ARTIFACTS_PASSWORD }} | ||||||||||
# source: /tmp/artifacts | ||||||||||
# if: always() | ||||||||||
|
||||||||||
quota-tests: | ||||||||||
runs-on: ubuntu-latest | ||||||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -1,4 +1,4 @@ | ||||||||||||||||
ARG NODE_VERSION=16.20.2-bookworm-slim | ||||||||||||||||
ARG NODE_VERSION=22.4.0-bookworm-slim | ||||||||||||||||
|
||||||||||||||||
FROM node:${NODE_VERSION} AS builder | ||||||||||||||||
|
||||||||||||||||
|
@@ -22,8 +22,10 @@ RUN apt-get update \ | |||||||||||||||
&& ssh-keyscan -H github.com > /root/ssh/known_hosts | ||||||||||||||||
|
||||||||||||||||
ENV PYTHON=python3 | ||||||||||||||||
RUN npm install -g node-gyp | ||||||||||||||||
COPY package.json yarn.lock /usr/src/app/ | ||||||||||||||||
RUN npm install [email protected] -g | ||||||||||||||||
|
||||||||||||||||
Comment on lines
+25
to
27
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. best to install all "global" packages in a single step,
Suggested change
|
||||||||||||||||
RUN yarn install --production --ignore-optional --frozen-lockfile --ignore-engines --network-concurrency 1 | ||||||||||||||||
|
||||||||||||||||
################################################################################ | ||||||||||||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env node | ||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
require('../lib/nfs/utilities.js').createBucketWithNFSEnabled(); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
#!/bin/sh | ||
// 2>/dev/null ; exec "$(which nodejs || which node)" "$0" "$@" | ||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
require('../lib/kms/utilities.js').createEncryptedBucket(); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env node | ||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
require('../lib/utapi/utilities.js').listMetrics('buckets'); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should keep this file, and just add early return (if needed) in |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env node | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should keep this file, and just add early return (if needed) in |
||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
require('../lib/utapi/utilities.js').listMetrics(); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
#!/usr/bin/env node | ||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
const { | ||
startWSManagementClient, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
#!/usr/bin/env node | ||
'use strict'; // eslint-disable-line strict | ||
'use strict'; | ||
|
||
const { | ||
startWSManagementClient, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
const fs = require('fs'); | ||
const path = require('path'); | ||
const url = require('url'); | ||
const crypto = require('crypto'); | ||
const mycrypto = require('crypto'); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why rename? |
||
|
||
const { v4: uuidv4 } = require('uuid'); | ||
const cronParser = require('cron-parser'); | ||
|
@@ -13,14 +13,11 @@ | |
const validateAuthConfig = arsenalAuth.inMemory.validateAuthConfig; | ||
const { buildAuthDataAccount } = require('./auth/in_memory/builder'); | ||
const validExternalBackends = require('../constants').externalBackends; | ||
const { | ||
azureAccountNameRegex, | ||
base64Regex, | ||
allowedUtapiEventFilterFields, | ||
allowedUtapiEventFilterStates, | ||
supportedLifecycleRules, | ||
const { azureAccountNameRegex, base64Regex, | ||
allowedUtapiEventFilterFields, allowedUtapiEventFilterStates, | ||
supportedLifecycleRules | ||
} = require('../constants'); | ||
Comment on lines
+16
to
19
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. change not needed? |
||
const { utapiVersion } = require('utapi'); | ||
// const { utapiVersion } = require('utapi'); | ||
const { scaleMsPerDay } = s3middleware.objectUtils; | ||
|
||
const constants = require('../constants'); | ||
|
@@ -1236,7 +1233,7 @@ | |
maxStaleness, | ||
enableInflights, | ||
}; | ||
if (config.utapi) { | ||
benzekrimaha marked this conversation as resolved.
Show resolved
Hide resolved
|
||
if (config.utapi && false) { // eslint-disable-line no-constant-condition | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no need to change, will work in case we don't have utapi? |
||
this.utapi = { component: 's3' }; | ||
if (config.utapi.host) { | ||
assert(typeof config.utapi.host === 'string', | ||
|
@@ -1249,7 +1246,7 @@ | |
'bad config: utapi port must be a positive integer'); | ||
this.utapi.port = config.utapi.port; | ||
} | ||
if (utapiVersion === 1) { | ||
if (utapiVersion === 1) { // eslint-disable-line no-undef | ||
if (config.utapi.workers !== undefined) { | ||
assert(Number.isInteger(config.utapi.workers) | ||
&& config.utapi.workers > 0, | ||
|
@@ -1349,7 +1346,7 @@ | |
} | ||
} | ||
|
||
if (utapiVersion === 2 && config.utapi.filter) { | ||
if (utapiVersion === 2 && config.utapi.filter) { // eslint-disable-line no-undef | ||
const { filter: filterConfig } = config.utapi; | ||
const utapiResourceFilters = {}; | ||
allowedUtapiEventFilterFields.forEach( | ||
|
@@ -1368,8 +1365,9 @@ | |
this.utapi.filter = utapiResourceFilters; | ||
} | ||
} | ||
// eslint-disable-next-line no-constant-condition | ||
if (Object.keys(this.locationConstraints).some( | ||
loc => this.locationConstraints[loc].sizeLimitGB)) { | ||
loc => this.locationConstraints[loc].sizeLimitGB) && false) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no need to 'fase' this, we should never run into this code anyway |
||
assert(this.utapi && this.utapi.metrics && | ||
this.utapi.metrics.includes('location'), | ||
'bad config: if storage size limit set on a location ' + | ||
|
@@ -1971,7 +1969,7 @@ | |
} | ||
|
||
setPublicInstanceId(instanceId) { | ||
this.publicInstanceId = crypto.createHash('sha256') | ||
this.publicInstanceId = mycrypto.createHash('sha256') | ||
.update(instanceId) | ||
.digest('hex'); | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
best to specify the version explicitely (24.04)