LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to automate installation commands? (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-automate-installation-commands-4175503255/)

ASTRAPI 04-28-2014 01:53 PM

How to automate installation commands?
 
Hello

I want to ask please how can i automate the commands that i run on Centos to install some software like:

Code:

wget linkhere
tar -xzf file.gz
chmod +x file.sh
blablabla


I want to create a file that will have all the commands inside and when i run it from the terminal to get all what i want ready to use..... and not to have run every command by hand?

Thank you

szboardstretcher 04-28-2014 01:58 PM

Here is a simple how-to on creating a shell script, which is what you are looking for.

http://www.linfo.org/create_shell_1.html

Please read it carefully, and follow the example. Once you have read it and completed the example, you will be able to turn your command list into a script that is executable.

ASTRAPI 04-28-2014 02:02 PM

Ok thanks but i am looking for something more advance than that with some sleep, sed commands and so on :)

szboardstretcher 04-28-2014 02:07 PM

No problem. But looking at your post, you did not request that.

You can certainly follow that guide, and put some sleep and sed commands into the script as well.

What is it that you are actually trying to do? And where are you in the process of doing it? Please explain.

ASTRAPI 04-28-2014 03:33 PM

When i setup my web server i am just installing some software (a lot) and i am thinking to do it automatically :)


All times are GMT -5. The time now is 05:13 AM.