@centreon/js-config 23.10.13 → 23.10.14

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.
@@ -92,29 +92,35 @@ Cypress.Commands.add(
92
92
 
93
93
  interface CopyFromContainerProps {
94
94
  destination: string;
95
+ name?: string;
95
96
  source: string;
96
97
  }
97
98
 
98
99
  Cypress.Commands.add(
99
100
  'copyFromContainer',
100
- ({ source, destination }: CopyFromContainerProps) => {
101
- return cy.exec(
102
- `docker cp ${Cypress.env('dockerName')}:${source} "${destination}"`
103
- );
101
+ ({
102
+ name = Cypress.env('dockerName'),
103
+ source,
104
+ destination
105
+ }: CopyFromContainerProps) => {
106
+ return cy.exec(`docker cp ${name}:${source} "${destination}"`);
104
107
  }
105
108
  );
106
109
 
107
110
  interface CopyToContainerProps {
108
111
  destination: string;
112
+ name?: string;
109
113
  source: string;
110
114
  }
111
115
 
112
116
  Cypress.Commands.add(
113
117
  'copyToContainer',
114
- ({ source, destination }: CopyToContainerProps) => {
115
- return cy.exec(
116
- `docker cp ${source} ${Cypress.env('dockerName')}:${destination}`
117
- );
118
+ ({
119
+ name = Cypress.env('dockerName'),
120
+ source,
121
+ destination
122
+ }: CopyToContainerProps) => {
123
+ return cy.exec(`docker cp ${source} ${name}:${destination}`);
118
124
  }
119
125
  );
120
126
 
@@ -273,26 +279,31 @@ Cypress.Commands.add(
273
279
  .exec(`mkdir -p "${logDirectory}"`)
274
280
  .copyFromContainer({
275
281
  destination: `${logDirectory}/broker`,
282
+ name,
276
283
  source: '/var/log/centreon-broker'
277
284
  })
278
285
  .copyFromContainer({
279
286
  destination: `${logDirectory}/engine`,
287
+ name,
280
288
  source: '/var/log/centreon-engine'
281
289
  })
282
290
  .copyFromContainer({
283
291
  destination: `${logDirectory}/centreon`,
292
+ name,
284
293
  source: '/var/log/centreon'
285
294
  })
286
295
  .then(() => {
287
296
  if (Cypress.env('WEB_IMAGE_OS').includes('alma')) {
288
297
  return cy.copyFromContainer({
289
298
  destination: `${logDirectory}/php`,
299
+ name,
290
300
  source: '/var/log/php-fpm'
291
301
  });
292
302
  }
293
303
 
294
304
  return cy.copyFromContainer({
295
- destination: `${logDirectory}/php/`,
305
+ destination: `${logDirectory}/php8.1-fpm-centreon-error.log`,
306
+ name,
296
307
  source: '/var/log/php8.1-fpm-centreon-error.log'
297
308
  });
298
309
  })
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@centreon/js-config",
3
3
  "description": "Centreon Frontend shared build configuration",
4
- "version": "23.10.13",
4
+ "version": "23.10.14",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "git+https://github.com/centreon/centreon-frontend.git"