Skip to content

Commit 64ee397

Browse files
committed
Improve verdaccio setup
1 parent 6dd7298 commit 64ee397

File tree

4 files changed

+46
-42
lines changed

4 files changed

+46
-42
lines changed

.circleci/verdaccio.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
storage: ./storage
2+
auth:
3+
htpasswd:
4+
file: ./htpasswd
5+
uplinks:
6+
npmjs:
7+
url: https://registry.yarnpkg.com/
8+
max_fails: 40
9+
maxage: 30m
10+
timeout: 60s
11+
fail_timeout: 10m
12+
cache: false
13+
agent_options:
14+
keepAlive: true
15+
maxSockets: 40
16+
maxFreeSockets: 10
17+
packages:
18+
# Group and isolate all local packages, avoid being proxy from outside
19+
'@react-native/*':
20+
access: $all
21+
publish: $all
22+
# The below specific entries can be removed once they are renamed and have the @react-native prefix
23+
'@react-native-community/eslint-config':
24+
access: $all
25+
publish: $all
26+
'@react-native-community/eslint-plugin':
27+
access: $all
28+
publish: $all
29+
'react-native-codegen':
30+
access: $all
31+
publish: $all
32+
'react-native-gradle-plugin':
33+
access: $all
34+
publish: $all
35+
'@*/*':
36+
access: $all
37+
publish: $authenticated
38+
proxy: npmjs
39+
'**':
40+
access: $all
41+
publish: $all
42+
proxy: npmjs
43+
logs:
44+
- {type: file, path: verdaccio.log, format: json, level: warn}

.circleci/verdaccio/config.yml

Lines changed: 0 additions & 27 deletions
This file was deleted.

scripts/run-ci-e2e-tests.js

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ try {
7575
const verdaccioProcess = spawn('npx', [
7676
'verdaccio@5.15.3',
7777
'--config',
78-
'.circleci/verdaccio/config.yml',
78+
'.circleci/verdaccio.yml',
7979
]);
8080
VERDACCIO_PID = verdaccioProcess.pid;
8181
exec('npx wait-on@6.0.1 http://localhost:4873');
@@ -92,19 +92,6 @@ try {
9292
packageName !== '@react-native/tester' &&
9393
packageName !== '@react-native/repo-config',
9494
)
95-
.filter(packageName => {
96-
const yarnInfo = exec(`yarn info ${packageName} --json`);
97-
if (yarnInfo.stderr !== '') {
98-
return true;
99-
}
100-
const versions = JSON.parse(
101-
exec(`yarn info ${packageName} --json`).stdout.trim(),
102-
).data.versions;
103-
const currentVersion = require(`${process.cwd()}/${
104-
packages[packageName].location
105-
}/package.json`).version;
106-
return !versions.includes(currentVersion);
107-
})
10895
.forEach(packageName => {
10996
exec(
11097
`cd ${packages[packageName].location} && npm publish --registry http://localhost:4873 --yes --access public`,

template/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"devDependencies": {
1717
"@babel/core": "^7.12.9",
1818
"@babel/runtime": "^7.12.5",
19-
"@react-native-community/eslint-config": "^2.0.0",
19+
"@react-native-community/eslint-config": "^3.0.0",
2020
"babel-jest": "^26.6.3",
2121
"eslint": "^8.19.0",
2222
"jest": "^26.6.3",

0 commit comments

Comments
 (0)