Skip to content

Instantly share code, notes, and snippets.

@vladdnepr
vladdnepr / ElasticaAsyncSubscriber.php
Created April 15, 2023 11:38
Solution For Index Aliases in FOS Elastica Bundle With Symfony Messenger. Required Symfony 6.2+
<?php
namespace App\Subscriber;
use FOS\ElasticaBundle\Elastica\Index;
use FOS\ElasticaBundle\Event\PostIndexPopulateEvent;
use FOS\ElasticaBundle\Event\PreIndexPopulateEvent;
use FOS\ElasticaBundle\Index\IndexManager;
use FOS\ElasticaBundle\Index\Resetter;
use FOS\ElasticaBundle\Message\AsyncPersistPage;
@yyandrew
yyandrew / ansistrano-build.yml
Last active November 3, 2023 23:28
Scripts to deploy react app by ansistrano
# .ansistrano/build.yml
- shell: cd "{{ ansistrano_deploy_to }}/current" && npm install
- shell: cd "{{ ansistrano_deploy_to }}/current" && npm run build
- shell: sudo chgrp -R nginx "{{ ansistrano_deploy_to }}/current/"