Как запустить приложение yugabyte-db yugastore локально?

Я использую yugabyte-db-1.3.0 и пытаюсь запустить пример приложения электронной коммерции yugabyte, yugastore локально на CentOS7, следуя инструкциям в README.md следующим образом:

a) downloaded and extracted application, yugastore to /var/www/html/yugastore
b) ./bin/yb-ctl start
c) cd /var/www/html/yugastore
c) yum install -y nodejs
d) npm install cassandra-driver
e) npm install redis
f) npm install async
g) ./bin/yb-ctl setup_redis
h) npm install
i) npm install --save core-js@^3
j) npm start

Я получаю сообщение об ошибке следующим образом:

[root@srvr0 yugastore]# npm start

> [email protected] start /var/www/html/yugastore
> supervisor ./bin/www


Running node-supervisor with
  program './bin/www'
  --watch '.'
  --extensions 'node,js,/bin/www'
  --exec 'node'

Starting child process with 'node ./bin/www'
Watching directory '/var/www/html/yugastore' for changes.
Press rs for restarting the process.
DB host: 127.0.0.1
/var/www/html/yugastore/ui/build/index.html
Error: ENOENT: no such file or directory, stat '/var/www/html/yugastore/ui/build/index.html'
    at Error (native)
GET /yugastore/ui/build/index.html 404 58.690 ms - 143

Пожалуйста, помогите мне в решении проблемы.

Обновление1:

Большое спасибо г-ну Дориану
Получил несколько предупреждений об устаревании, так как я использую более раннюю версию CentOS7. Просто удалось запустить приложение со следующими шагами:

cd ~
rm -rf /opt/yugabyte
mkdir -p /opt/yugabyte
mkdir -p /opt/yugabyte/data
cd /tmp
wget https://downloads.yugabyte.com/yugabyte-1.3.0.0-linux.tar.gz
tar -xvzf /tmp/yugabyte/yugabyte-1.3.0.0-linux.tar.gz -C /opt/yugabyte
cd /opt/yugabyte/yugabyte-1.3.0.0
/opt/yugabyte/yugabyte-1.3.0.0/bin/post_install.sh
/opt/yugabyte/yugabyte-1.3.0.0/bin/yb-ctl --data_dir "/opt/yugabyte/data" destroy
/opt/yugabyte/yugabyte-1.3.0.0/bin/yb-ctl --data_dir "/opt/yugabyte/data" create
/opt/yugabyte/yugabyte-1.3.0.0/bin/yb-ctl --data_dir "/opt/yugabyte/data" stop
/opt/yugabyte/yugabyte-1.3.0.0/bin/yb-ctl --data_dir "/opt/yugabyte/data" start
/opt/yugabyte/yugabyte-1.3.0.0/bin/yb-ctl --data_dir "/opt/yugabyte/data" setup_redis

cd ~
rm -rf /var/www/html/yugastore
cd /tmp
git clone https://github.com/yugabyte/yugastore
cd /tmp/yugastore
tar -cvzf /tmp/yugastore.tar.gz .
mkdir -p /var/www/html/yugastore
tar -xvzf /tmp/yugastore.tar.gz -C /var/www/html/yugastore

cd /var/www/html/yugastore
npm install cassandra-driver
npm install redis
npm install async
npm install
npm install --save core-js@^3
node models/yugabyte/db_init.js
npm start

###In another terminal:
cd /var/www/html/yugastore/ui
npm install
npm start

person AVA    schedule 09.01.2020    source источник


Ответы (1)


Вы используете очень старую версию YugabyteDB. 2.0.10 является последним по состоянию на 9 января 2020 г.

И похоже, что у вас несоответствие пути. Можете ли вы проверить, что файлы есть и сборка завершена правильно?

Загрузите и установите (https://download.yugabyte.com) базу данных:

wget https://downloads.yugabyte.com/yugabyte-2.0.10.0-linux.tar.gz
tar xvfz yugabyte-2.0.10.0-linux.tar.gz && cd yugabyte-2.0.10.0/
./bin/post_install.sh
./bin/yb-ctl create
./bin/yb-ctl setup_redis

Загрузите и установите yugastore: (https://github.com/yugabyte/yugastore#run-locally< /а>)

git clone https://github.com/yugabyte/yugastore
cd yugastore
node models/yugabyte/db_init.js
npm start

в другой оболочке:

cd yugastore/ui
npm install # First time only
npm start

Откроется новая вкладка с сайтом.

person dorian YB    schedule 09.01.2020
comment
Я новичок в этих технологиях. Пожалуйста, подскажите, как проверить успешную сборку. например проверка журнала... - person AVA; 10.01.2020
comment
красивая эстетика! спасибо команде приложения yugastore! - person AVA; 11.01.2020