Download the PHP package proklung/bitrix-symfony-base.git without Composer
On this page you can find all versions of the php package proklung/bitrix-symfony-base.git. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package bitrix-symfony-base.git
Bitrix Project + Symfony
Заготовка для 1C Bitrix проектов. На базе https://github.com/regiomedia/bitrix-project
Основное отличие: максимальное использование Symfony. Поддерживаются бандлы, сервис контейнер с полным функционалом фрэймворка (аннотации, auto wiring), роутинг, консоль и так далее.
От Битрикса остается админка, база, компоненты (где контейнер доступен через сервис-локатор). Все остальное пишется в максимально приближенной к Symfony манере.
Плюс всевозможный - используемый мною в реальных проектах - функционал (размещается в бандлах Symfony).
А также плоды всевозможных досужих экспериментов, оказавшихся полезными в работе.
Создание нового проекта
- Создать папку нового проекта в OSPanel/domains и Клонировать эту базовую сборку
К примеру:
-
Настроить вебсервер для работы с директорией
sites/s1
либо сделать симлинк вида(Настроить локальный домен в OpenServer со ссылкой на sites/s1)
Зависимости
-
Установить зависимости composer (backend):
- Установить зависимости npm (frontend):
Bitrix
- Удалить папку bitrix
-
Инициализировать submodule:
- Запустить submodule (cклонируется bitrix):
Или настроить его иным способом (через git submodule ad).
ВАЖНО
Перед этой процедурой обновить include.php
в environments/*/bitrix/modules/main
, на актуальный из сабмодуля
или устанавливаемого иным способом Битрикса.
После этого рекомендуется сделать еще разок composer update
дабы подтянулись битриксовые модули.
Символьные ссылки
В директорию sites/s1
перенести публичные файлы сайта.
В виндовом терминале:
База данных и окружение
-
Создать базу данных на localhost
-
Развернуть бэкап базы из bitrix/backup
-
Создать файл
.env
-
Заполнить его данными в соответствии с файлом-образцом
.env.example
- Развернуть окружение
sh php migrator install sh php migrator migrate sh npm run encore -- dev sh composer run lint:php sh composer run fix:php sh npm run encore -- dev # запустить сборку для разработчика один раз npm run encore -- dev --watch # запустить сборку для разработчика в режиме слежения за файлами npm run encore -- production # запустить сборку для продакшена html
html
js import DemoApp from './components/DemoApp.vue';
export default { DemoApp, };
mkdir sites/s2 # создать директорию для дополнительного сайта cd sites/s2 # перейти в нее mklink "local" "../../local" /j mklink "bitrix" "../../bitrix" /j mklink "upload" "../../upload" /j
json "scripts": { "post-update-cmd": [ "Local\ComposerScript\RunMigrationsHandler::doInstall", "Local\ComposerScript\CacheWarmerHandler::doInstall" ], "post-install-cmd": [ "Local\ComposerScript\RunMigrationsHandler::doInstall", "Local\ComposerScript\CacheWarmerHandler::doInstall" ], "cache:warm": "Local\ComposerScript\CacheWarmerHandler::doInstall", "migrations:run": "Local\ComposerScript\RunMigrationsHandler::doInstall" }, sh composer cache:warm sh composer migrations:run
## Прочее
- Пришлось залочить пакет `psr/container` на версию 1.0. Без этого ставился 1.1.1 (по запросу Symfony DI)
и конструкция падала из-за несоответствия интерфейсов.
Последствия: DI компонент пока версии 5.2, а не актуальной 5.3.
All versions of bitrix-symfony-base.git with dependencies
psr/container Version 1.0.*
proklung/core-framework-extension-bundle Version ^1.8
proklung/core-argument-resolvers-bundle Version ^1.1
proklung/bitrixsymfonyrouterbundle Version ^1.4
proklung/bitrix-twig-bundle Version ^1.0
arrilot/bitrix-migrations Version dev-master
arrilot/bitrix-models Version dev-master
maximaster/tools.twig Version dev-master
bitrix-expert/bbc Version ^1.0
proklung/jedi-light Version ^1.0
illuminate/support Version ^6.0 || ^7.0
symfony/dotenv Version ^5.2
symfony/monolog-bundle Version ^3.7
proklung/facade-bundle Version ^1.0
proklung/bitrixstaticpagemakerbundle Version ^1.0
proklung/bitrix-custom-properties-bundle Version ^1.1
proklung/bitrix-webform-bundle Version ^1.0
proklung/pipeline-symfony Version ^1.0
proklung/db-command Version ^1.0
proklung/bitrix-iblock-element-validator-bundle Version ^1.0
proklung/framework-tools-bundle Version ^1.5
proklung/twig-extensions-bundle Version ^1.6