-
Notifications
You must be signed in to change notification settings - Fork 278
how does one test portal ui src changes locally?
Cesar Celis Hernandez edited this page Apr 24, 2022
·
5 revisions
- Run MinIO Server:
MINIO_ROOT_USER=minio MINIO_ROOT_PASSWORD=minio123 minio server /Volumes/data{1...4} --address :9000 --console-address :9001
- Then run console server
cd ~/console
make install
~/go/bin/console server
- Run UI/React part via Yarn:
cd ~/console/portal-ui
yarn install
yarn build
yarn run start
- Go to http://localhost:5005/ and copy curl command from the Developer Tool:
curl 'http://localhost:5005/api/v1/buckets' \
-H 'Accept: */*' \
-H 'Accept-Language: en-CA,en-GB;q=0.9,en-US;q=0.8,en;q=0.7' \
-H 'Connection: keep-alive' \
-H 'Cookie: token=AbYulJ6iItfkaldj2FcfjjjdXJQM1d2qTbnzqIBXCvR+irB5Y2NcCJteHhZ537xzUcsAP6qXO61PjMZxYSH4gqSNpoJI58FMPoz2RkPO1O+doZOf/9mYri15ytd7ertGFD7nPG89736weVuu1Mo4mM54g2Yk/T+mxutbuXU/Mr1f2MpdstSZExaFPKtgDtBwzFvHX9uc+EKNrtodxuMgIeS1kzepZM7R0AWofh1UXNUW4G3ENE/NZd2Nh7FXGGkn9iU6xo7OEyxWhKyjmJFlvYoXGQ1N8Bajcn6ck3dcLJ8LKvdLonGyVHwamcVCjrS6kIuLqRtBaYkdbzMK/DNk4qTDA7ERnMyJL1butj+oygSHtbM/a8NIuNuzq1+jw1HhGucDGDZXOaLFOiY+N/w1p62xZaiKXj/tUZw/0w4yZJ7Ch+0rI6FAWOVAtDYSdGOH5ZjGVqJ47RZhUphqJiKynducU8y/9U8z2Vlujy18NgmVgGf3uiIJPqRq0y5HFigZYjRJZEL+rjSh4P3Fg0kJ1j0Qh2U/V8OXuOh29DoUTHI=' \
-H 'Referer: http://localhost:5005/buckets' \
-H 'Sec-Fetch-Dest: empty' \
-H 'Sec-Fetch-Mode: cors' \
-H 'Sec-Fetch-Site: same-origin' \
-H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36' \
-H 'sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="100", "Google Chrome";v="100"' \
-H 'sec-ch-ua-mobile: ?0' \
-H 'sec-ch-ua-platform: "macOS"' \
--compressed
As a response you get:
{
"buckets": [
{
"creation_date": "2022-04-07T12:44:24-04:00",
"details": {
"quota": {},
"versioning": true
},
"name": "bucket",
"objects": 2,
"rw_access": {
"read": true,
"write": true
},
"size": 7815
},
{
"creation_date": "2022-04-11T17:28:14-04:00",
"details": {
"quota": {}
},
"name": "bucket1",
"rw_access": {
"read": true,
"write": true
}
},
{
"creation_date": "2022-04-11T17:40:52-04:00",
"details": {
"quota": {}
},
"name": "bucket2",
"objects": 1,
"rw_access": {
"read": true,
"write": true
},
"size": 7031
},
{
"creation_date": "2022-04-11T17:56:37-04:00",
"details": {
"quota": {}
},
"name": "cesar",
"objects": 1,
"rw_access": {
"read": true,
"write": true
},
"size": 2412
},
{
"creation_date": "2022-04-07T13:36:53-04:00",
"details": {
"quota": {},
"versioning": true
},
"name": "cmee",
"rw_access": {
"read": true,
"write": true
}
},
{
"creation_date": "2022-04-11T18:04:24-04:00",
"details": {
"quota": {}
},
"name": "f234432",
"objects": 2,
"rw_access": {
"read": true,
"write": true
},
"size": 37820
},
{
"creation_date": "2022-04-24T20:31:11Z",
"details": {
"quota": {}
},
"name": "test",
"objects": 2,
"rw_access": {
"read": true,
"write": true
},
"size": 708726
},
{
"creation_date": "2022-04-24T20:31:11Z",
"details": {
"quota": {}
},
"name": "test2",
"rw_access": {
"read": true,
"write": true
}
},
{
"creation_date": "2022-04-24T20:31:11Z",
"details": {
"quota": {}
},
"name": "testbucket",
"objects": 1,
"rw_access": {
"read": true,
"write": true
},
"size": 41731
},
{
"creation_date": "2022-04-11T18:40:02-04:00",
"details": {
"quota": {}
},
"name": "user1",
"objects": 1,
"rw_access": {
"read": true,
"write": true
},
"size": 1916
},
{
"creation_date": "2022-04-07T08:15:24-04:00",
"details": {
"quota": {},
"versioning": true
},
"name": "versionedbucket",
"rw_access": {
"read": true,
"write": true
}
},
{
"creation_date": "2022-04-07T11:29:17-04:00",
"details": {
"quota": {}
},
"name": "versions",
"rw_access": {
"read": true,
"write": true
}
},
{
"creation_date": "2022-04-07T11:29:25-04:00",
"details": {
"quota": {},
"versioning": true
},
"name": "versions2",
"objects": 1,
"rw_access": {
"read": true,
"write": true
},
"size": 77680
}
],
"total": 13
}
- Any change you perform to React/JS files will show up right away, no need to re-compile anything.