i installed phpmyadmin on elastic beanstalk application and i got the following error "Wrong permissions on configuration file, should not be world writable!"
every time i deploy code to the application i have to go on server and change manually the file permission,
i tried to add a .config file in the .ebextensions folder to run sudo chmod 755 /path-to-file
in the log it looks good but in fact it's still 666
here is the file
.ebextensions/phpdb.config
container_commands:
01_change_permissions:
command: "sudo chmod 000755 /var/app/current/phpdb/config.inc.php"
ignoreErrors: true
02_change_permissions:
command: "/opt/elasticbeanstalk/hooks/appdeploy/post/99_change_permissions.sh"
files:
"/opt/elasticbeanstalk/hooks/appdeploy/post/99_change_permissions.sh":
mode: "000755"
owner: root
group: root
content: |
#!/usr/bin/env bash
sudo chmod 000755 /var/app/current/phpdb/config.inc.php