GithubHelp home page GithubHelp logo

redskyby / client_for_dictionary Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 301 KB

This is the client part of my application that helps me learn English.

HTML 1.05% TypeScript 70.78% JavaScript 1.28% SCSS 26.89%

client_for_dictionary's Introduction

client_for_dictionary

This is the client part of my application that helps me learn English.

Установка Nginx на Ubuntu Обновление списка пакетов:

sudo apt update

Установка Nginx:

sudo apt install nginx

Проверка статуса Nginx:

sudo systemctl status nginx

Эта команда покажет, запущен ли Nginx. Если он запущен, вы увидите сообщение о том, что он работает.

Эта конфигурация Nginx

server {listen 80;
server_name your_domain.com;

location / {
    # Путь к статическим файлам React-приложения
    root /path/to/your/react/app/build;
    index index.html;
    try_files $uri /index.html;
}
location /api {
    # Проксирование запросов к серверу Express на порт 5000
    proxy_pass http://localhost:5000;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
}}

Эта конфигурация Nginx настраивает проксирование запросов к серверу Express на порт 5000 для всех URL, начинающихся с /api. При этом все остальные запросы обрабатываются статическим React-приложением.

Не забудьте заменить /path/to/your/react/app/build на путь к вашему React-приложению. Также убедитесь, что ваш сервер Express настроен для обработки запросов, отправленных на путь /api.

client_for_dictionary's People

Contributors

redskyby avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.