0
에 Symfony2, LiipImagineBundle 및 Gaufrette와 AmazonS3 파일 URL을 생성합니다.오류가 나는 Symfony2에 LiipImagineBundle를 사용 amazonS3 이미지를 잡으려고 gaufrette와 <br> 을 통합하려고하지만, 이미지에 내 "SRC는"잘못하고있어 나뭇 가지
{{ '123.jpg' | imagine_filter('128_128_75_s3') }}
// return http://localhost/project/web/media/cache/resolve/128_128_75_s3/123.jpg
// expected is http://bucket.s3.amazonaws.com/media/cache/resolve/128_128_75_s3/123.jpg
내 sevices.yml :
services:
amazonS3:
class: AmazonS3
arguments:
options:
key: %aws_key%
secret: %aws_secret%
liip_imagine.cache.resolver.amazon_s3:
class: Liip\ImagineBundle\Imagine\Cache\Resolver\AmazonS3Resolver
arguments:
- "@amazonS3"
- "%aws_bucket%"
tags:
- { name: 'liip_imagine.cache.resolver', resolver: 'resolver.amazon' }
liip_imagine.binary.loader.stream.import:
class: Liip\ImagineBundle\Binary\Loader\StreamLoader
arguments:
- 'gaufrette://import/'
tags:
- { name: 'liip_imagine.binary.loader', loader: 'import' }
내 config.yml :
오류가 내 CONFIGS 그렇다면 나는 ...이 나뭇 가지 코드 모른다
# Gaufrette media bundle
knp_gaufrette:
adapters:
import:
amazon_s3:
amazon_s3_id: amazonS3
bucket_name: %aws_bucket%
options:
create: true
filesystems:
import:
adapter: import
alias: import
stream_wrapper: ~
#Liip Imagine Bundle
liip_imagine:
cache: resolver.amazon
data_loader: stream.import
filter_sets:
128_128_75_s3:
quality: 75
filters:
thumbnail: { size: [128, 128], mode: outbound }
[이 github 문제] (https://github.com/liip/LiipImagineBundle/issues/496)를보십시오. 희망이 도움이 – Matteo