wallabag/app/config/services.yml

352 lines
12 KiB
YAML
Raw Normal View History

imports:
- { resource: services_rabbit.yml }
- { resource: services_redis.yml }
- { resource: parameters_addons.yml }
2015-01-22 07:30:07 +00:00
parameters:
2024-02-19 00:30:12 +00:00
spiriit_form_filter.get_filter.doctrine_orm.class: Wallabag\Event\Subscriber\CustomDoctrineORMSubscriber
2015-01-22 07:30:07 +00:00
services:
2022-08-27 17:26:16 +00:00
_defaults:
autowire: true
autoconfigure: true
public: true
bind:
$projectDir: '%kernel.project_dir%'
$debug: '%kernel.debug%'
$defaultLocale: '%kernel.default_locale%'
$wallabagUrl: '%domain_name%'
$tablePrefix: "%database_table_prefix%"
2024-02-19 23:47:53 +00:00
$encryptionKeyPath: "%wallabag.site_credentials.encryption_key_path%"
$fetchingErrorMessageTitle: "%wallabag.fetching_error_message_title%"
$fetchingErrorMessage: '%wallabag.fetching_error_message%'
$languages: '%wallabag.languages%'
$lifeTime: '%wallabag.cache_lifetime%'
$cookieFile: "%kernel.cache_dir%/cookiejar.json"
$logoPath: 'web/img/appicon/apple-touch-icon-152.png'
$registrationEnabled: '%fosuser_registration%'
$restrictedAccess: '@=service(''craue_config'').get(''restricted_access'')'
$senderEmail: "%scheb_two_factor.email.sender_email%"
$senderName: "%scheb_two_factor.email.sender_name%"
$storeArticleHeaders: '@=service(''craue_config'').get(''store_article_headers'')'
$supportUrl: '@=service(''craue_config'').get(''wallabag_support_url'')'
2024-02-19 23:47:53 +00:00
$fonts: '%wallabag.fonts%'
2022-08-27 17:26:16 +00:00
2024-02-19 00:30:12 +00:00
Wallabag\:
resource: '../../src/*'
exclude: ['../../src/{Consumer,Controller,Entity,ExpressionLanguage,DataFixtures,Redis}', '../../src/Event/*Event.php']
2022-08-27 23:07:59 +00:00
# controllers are imported separately to make sure services can be injected
# as action arguments even if you don't extend any base controller class
2024-02-19 00:30:12 +00:00
Wallabag\Controller\:
resource: '../../src/Controller/'
tags: ['controller.service_arguments']
# inject alias service into controllers
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\ChromeController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_chrome_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.chrome'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\DeliciousController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_delicious_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.delicious'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\ElcuratorController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_elcurator_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.elcurator'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\FirefoxController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_firefox_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.firefox'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\InstapaperController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_instapaper_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.instapaper'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\PinboardController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_pinboard_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.pinboard'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\PocketController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_pocket_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.pocket'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\ReadabilityController:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_readability_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.readability'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\WallabagV1Controller:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_wallabag_v1_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.wallabag_v1'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\WallabagV2Controller:
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_wallabag_v2_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.wallabag_v2'
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\ShaarliController:
2023-07-26 10:49:30 +00:00
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_shaarli_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.shaarli'
2023-07-26 10:49:30 +00:00
2024-02-19 00:30:12 +00:00
Wallabag\Controller\Import\PocketHtmlController:
2023-07-26 10:49:30 +00:00
arguments:
$rabbitMqProducer: '@old_sound_rabbit_mq.import_pocket_html_producer'
2024-02-19 23:47:53 +00:00
$redisProducer: '@wallabag.producer.redis.pocket_html'
2023-07-26 10:49:30 +00:00
2022-08-28 00:01:46 +00:00
Doctrine\DBAL\Connection:
alias: doctrine.dbal.default_connection
Doctrine\ORM\EntityManagerInterface:
alias: doctrine.orm.entity_manager
Doctrine\Migrations\Metadata\Storage\TableMetadataStorageConfiguration:
alias: doctrine.migrations.storage.table_storage
2022-08-28 00:01:46 +00:00
Doctrine\Persistence\ManagerRegistry:
alias: doctrine
Craue\ConfigBundle\Util\Config:
alias: craue_config
JMS\Serializer\SerializerInterface:
alias: jms_serializer
Spiriit\Bundle\FormFilterBundle\Filter\FilterBuilderUpdaterInterface:
alias: spiriit_form_filter.query_builder_updater
2022-08-28 00:01:46 +00:00
Scheb\TwoFactorBundle\Security\TwoFactor\Provider\Google\GoogleAuthenticatorInterface:
alias: scheb_two_factor.security.google_authenticator
Symfony\Component\HttpFoundation\Session\SessionInterface:
alias: session
Symfony\Component\EventDispatcher\EventDispatcherInterface:
alias: event_dispatcher
Symfony\Component\Form\FormFactoryInterface:
alias: form.factory
Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface:
alias: security.token_storage
Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface:
alias: security.authorization_checker
Symfony\Component\Translation\TranslatorInterface:
alias: translator
Symfony\Component\Validator\Validator\ValidatorInterface:
alias: validator
FOS\UserBundle\Model\UserManagerInterface:
alias: fos_user.user_manager
MatomoTwigExtension\MatomoTwigExtension:
2016-02-19 14:27:57 +00:00
public: false
ScssPhp\ScssPhp\Compiler:
public: false
2024-02-19 00:30:12 +00:00
Wallabag\Event\Listener\UserLocaleListener:
2015-10-01 14:28:38 +00:00
tags:
- { name: kernel.event_listener, event: security.interactive_login, method: onInteractiveLogin }
2017-05-12 14:33:12 +00:00
craue_config_cache_provider:
class: Symfony\Component\Cache\Adapter\FilesystemAdapter
public: false
arguments:
2022-08-27 18:22:48 +00:00
$namespace: 'craue_config'
$defaultLifetime: 0
$directory: '%kernel.cache_dir%'
2024-02-19 00:30:12 +00:00
Wallabag\ParamConverter\UsernameFeedTokenConverter:
tags:
- { name: request.param_converter, converter: username_feed_token_converter }
2024-02-19 00:30:12 +00:00
Wallabag\Event\Subscriber\TablePrefixSubscriber:
tags:
- { name: doctrine.event_subscriber }
2024-03-10 16:30:29 +00:00
Wallabag\Event\Subscriber\SchemaAdapterSubscriber:
arguments:
$databaseTablePrefix: "%database_table_prefix%"
tags:
- { name: doctrine.event_subscriber }
Graby\Graby:
arguments:
2022-08-27 18:22:48 +00:00
$config:
2024-02-19 23:47:53 +00:00
error_message: '%wallabag.fetching_error_message%'
error_message_title: '%wallabag.fetching_error_message_title%'
calls:
- [ setLogger, [ "@logger" ] ]
tags:
- { name: monolog.logger, channel: graby }
Graby\SiteConfig\ConfigBuilder:
arguments:
2022-08-27 18:22:48 +00:00
$config: {}
2024-02-19 23:47:53 +00:00
wallabag.http_client:
alias: 'httplug.client.wallabag'
2024-02-19 00:30:12 +00:00
Wallabag\SiteConfig\GrabySiteConfigBuilder:
tags:
- { name: monolog.logger, channel: graby }
# service alias override
2024-02-19 00:30:12 +00:00
Wallabag\SiteConfig\SiteConfigBuilder:
alias: Wallabag\SiteConfig\GrabySiteConfigBuilder
2022-11-14 22:11:46 +00:00
GuzzleHttp\Cookie\CookieJar:
2024-02-19 00:30:12 +00:00
alias: 'Wallabag\Helper\FileCookieJar'
2022-11-14 22:11:46 +00:00
2024-02-19 00:30:12 +00:00
Wallabag\Helper\HttpClientFactory:
calls:
2024-02-19 00:30:12 +00:00
- ['addSubscriber', ['@Wallabag\Guzzle\AuthenticatorSubscriber']]
- ['addSubscriber', ['@Wallabag\Guzzle\FixupMondeDiplomatiqueUriSubscriber']]
RulerZ\RulerZ:
alias: rulerz
2024-02-19 00:30:12 +00:00
Wallabag\Operator\PHP\Matches:
tags:
- { name: rulerz.operator, target: native, operator: matches }
2024-02-19 00:30:12 +00:00
Wallabag\Operator\Doctrine\Matches:
tags:
- { name: rulerz.operator, target: doctrine, operator: matches, inline: true }
2024-02-19 00:30:12 +00:00
Wallabag\Operator\PHP\NotMatches:
tags:
- { name: rulerz.operator, target: native, operator: notmatches }
2024-02-19 00:30:12 +00:00
Wallabag\Operator\Doctrine\NotMatches:
tags:
- { name: rulerz.operator, target: doctrine, operator: notmatches, inline: true }
2024-02-19 00:30:12 +00:00
Wallabag\Operator\PHP\PatternMatches:
tags:
- { name: rulerz.operator, target: native, operator: "~" }
Predis\Client:
arguments:
2022-08-27 18:22:48 +00:00
$parameters:
scheme: '%redis_scheme%'
host: '%redis_host%'
port: '%redis_port%'
path: '%redis_path%'
password: '%redis_password%'
2024-02-19 00:30:12 +00:00
Wallabag\Event\Subscriber\SQLiteCascadeDeleteSubscriber:
tags:
- { name: doctrine.event_subscriber }
2024-02-19 00:30:12 +00:00
Wallabag\Event\Subscriber\DownloadImagesSubscriber:
arguments:
2022-08-27 18:22:48 +00:00
$enabled: '@=service(''craue_config'').get(''download_images_enabled'')'
2024-02-19 00:30:12 +00:00
Wallabag\Helper\DownloadImages:
arguments:
2022-08-27 18:22:48 +00:00
$baseFolder: "%kernel.project_dir%/web/assets/images"
2024-02-19 00:30:12 +00:00
Wallabag\Command\InstallCommand:
arguments:
$databaseDriver: '%database_driver%'
2024-02-19 23:47:53 +00:00
$defaultSettings: '%wallabag.default_internal_settings%'
$defaultIgnoreOriginInstanceRules: '%wallabag.default_ignore_origin_instance_rules%'
2024-02-19 00:30:12 +00:00
Wallabag\Mailer\UserMailer:
2022-12-15 11:02:52 +00:00
arguments:
$parameters:
template:
confirmation: '%fos_user.registration.confirmation.template%'
resetting: '%fos_user.resetting.email.template%'
from_email:
confirmation: '%fos_user.registration.confirmation.from_email%'
resetting: '%fos_user.resetting.email.from_email%'
2024-02-19 00:30:12 +00:00
Wallabag\Event\Listener\CreateConfigListener:
arguments:
2024-02-19 23:47:53 +00:00
$itemsOnPage: "%wallabag.items_on_page%"
$feedLimit: "%wallabag.feed_limit%"
$language: "%wallabag.language%"
$readingSpeed: "%wallabag.reading_speed%"
$actionMarkAsRead: "%wallabag.action_mark_as_read%"
$listMode: "%wallabag.list_mode%"
$displayThumbnails: "%wallabag.display_thumbnails%"
2024-02-19 00:30:12 +00:00
Wallabag\Event\Listener\AuthenticationFailureListener:
tags:
- { name: kernel.event_listener, event: security.authentication.failure, method: onAuthenticationFailure }
2024-02-19 00:30:12 +00:00
Wallabag\Import\PocketImport:
calls:
2024-02-08 22:23:11 +00:00
- [ setClient, [ '@Symfony\Contracts\HttpClient\HttpClientInterface $pocketClient' ] ]
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: pocket }
2024-02-19 00:30:12 +00:00
Wallabag\Import\WallabagV1Import:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: wallabag_v1 }
2024-02-19 00:30:12 +00:00
Wallabag\Import\WallabagV2Import:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: wallabag_v2 }
2024-02-19 00:30:12 +00:00
Wallabag\Import\ElcuratorImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: elcurator }
2024-02-19 00:30:12 +00:00
Wallabag\Import\ReadabilityImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: readability }
2024-02-19 00:30:12 +00:00
Wallabag\Import\InstapaperImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: instapaper }
2024-02-19 00:30:12 +00:00
Wallabag\Import\PinboardImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: pinboard }
2024-02-19 00:30:12 +00:00
Wallabag\Import\DeliciousImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: delicious }
2024-02-19 00:30:12 +00:00
Wallabag\Import\FirefoxImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: firefox }
2024-02-19 00:30:12 +00:00
Wallabag\Import\ChromeImport:
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: chrome }
2022-12-14 13:36:29 +00:00
2024-02-19 00:30:12 +00:00
Wallabag\Import\ShaarliImport:
2023-07-26 10:49:30 +00:00
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: shaarli }
2023-07-26 10:49:30 +00:00
2024-02-19 00:30:12 +00:00
Wallabag\Import\PocketHtmlImport:
2023-07-26 10:49:30 +00:00
tags:
2024-02-19 23:47:53 +00:00
- { name: wallabag.import, alias: pocket_html }
2023-07-26 10:49:30 +00:00
2022-12-14 13:36:29 +00:00
# to factorize the proximity and bypass translation for prev & next
pagerfanta.view.default_wallabag:
class: Pagerfanta\View\OptionableView
arguments:
- '@pagerfanta.view.twitter_bootstrap'
- { proximity: 1, prev_message: "<", next_message: ">" }
public: false
tags:
- { name: pagerfanta.view, alias: default_wallabag }