1
我想为我的symfony弹性beanstalk PHP应用程序实现基本的http auth。我已经发现了this link where it is explained for an other php project并为我的symfony需求调整了一点点。PHP/Symfony弹性beanstalk basic http auth
files:
"/etc/httpd/conf.d/allow_override.conf":
mode: "000644"
owner: ec2-user
group: ec2-user
encoding: plain
content: |
<Directory /var/www/html/www/ />
AllowOverride AuthConfig
</Directory>
"/etc/httpd/conf.d/auth.conf":
mode: "000644"
owner: ec2-user
group: ec2-user
encoding: plain
content: |
<Directory /var/www/html/www/ />
AuthType Basic
AuthName "Myproject Prototype"
AuthUserFile /etc/httpd/.htpasswd
Require valid-user
</Directory>
"/etc/httpd/.htpasswd":
mode: "000644"
owner: ec2-user
group: ec2-user
encoding: plain
content: |
admin:lala
问题是:我不知道在那里设置了什么目录。 我想:
- 在/ var/www/html等/网络/
- 在/ var/www/html等/ WWW
- 在/ var/www/html等/
- 在/ var/www/html等
但这一切都没有工作。我得到的一些错误503
哎,感谢您的答复:) /www是还好吧,因为某些原因,文件夹命名为这样。但AllowOverride信息是新的。非常感谢你! 在此期间,我通过vpn访问解决了我的原始问题:) –