Jump to content

Recommended Posts

Hi all !

 

I have been trying to automate some simple tasks using the configuration files. However, while i do not get any errors in my log files and the application is deployed successfully, the configuration files are not executed or so it seems ( else I would get an error if they failed).

 

Here is two files configuration files that I was just trying out. 

 

21_copy_xsendfile_conf.config:

files:
  "/home/ec2-user/21_copy_xsendfile_conf.sh":
    mode: "000750"
    owner: root
    group: root
    content: |
	  #!bin/bash
          cp scripts/activate_xsendfile.conf /etc/httpd/conf.d/ 

another version of the same as above ( since I was not sure which was correct ) :-

 

21_copy_xsendfile_conf.config:

files:
  "/home/ec2-user/21_copy_xsendfile_conf.sh":
    mode: "000750"
    owner: root
    group: root
    content: |
	  #!bin/bash
          cp scripts/activate_xsendfile.conf /etc/httpd/conf.d/ 

and then the 2nd config file to install the xsendfile module:

 

22_copy_to_conf.config:

container_commands:
  21_copy_to_conf:
    command: "/home/ec2-user/21_copy_xsendfile_conf.sh"

All the config files are placed in the .ebextensions folder. Both versions of the 1st file and the 2nd file seem not to work. I do not get any error either. 

 

I am assuming that the code in these files is correct since I do not get any error either. Please can someone point what the mistake or how i may go about it. 

 

The folder structure is      myprojects

                                              |-------- .ebextensions

                                                             |---------- .config files

                                              |--------- project

                                                             |----------index.php

                                              |---------scripts

                                                             |

                                                             |------ activate_xsendfile.conf

 

Thanks all !!

Edited by ajoo
Link to comment
https://forums.phpfreaks.com/topic/305211-need-an-aws-configuration-files-example/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.