from chibi.command import yum, git, command from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir, join, exists, current_dir, cd cache_dir = inflate_dir( '~/.cache' ) file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "ponysay\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "Starting install for ponysay" ) yum.install( 'texinfo' ) original_dir = current_dir() cd( cache_dir ) ponysay_dir = join( cache_dir, 'ponysay' ) if not exists( ponysay_dir ): git.clone( 'https://github.com/erkin/ponysay.git', ponysay_dir ) cd( ponysay_dir ) command( 'python3', './setup.py', 'install', '--freedom=partial' ) cd( original_dir ) file_check.append( version_to_check )
#!/usr/bin/env python3 from chibi.command import yum, systemctl, command from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir('~/provision_installed') file_check = Chibi_file(file_check_path) version_to_check = "redis\n".format(file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay("instalado redis") yum.install('redis') systemctl.start("redis") systemctl.enable("redis") cowsay("termino de instalar redis") result, error, return_code = command('redis-cli', 'ping', stdout='pipe') cowsay("redis ping say: {}".format(result)) file_check.append(version_to_check)
from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir from chibi.net import download file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "erlang\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "instalando erlang" ) yum.install( 'gcc', 'gcc-c++', 'glibc-devel', 'make', 'ncurses-devel', 'openssl-devel', 'autoconf', 'java-1.8.0-openjdk-devel', 'git', 'wget', 'wxBase.x86_64' ) download( "http://packages.erlang-solutions.com/" "erlang-solutions-1.0-1.noarch.rpm", directory='/tmp', file_name='erlang.rpm' ) rpm.rpm( '-Uvh', '/tmp/erlang.rpm' ) yum.install( 'erlang' ) file_check.append( version_to_check ) cowsay( " termino de instalar erlang" )
#!/usr/bin/env python3 from chibi.command import yum, echo from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "{file}\n".format( file=__file__ ) if __name__ == "__main__" and not version_to_check in file_check: echo.cowsay( "updating centos" ) yum.update() yum.install( 'epel-release' ) file_check.append( version_to_check ) echo.cowsay( "end of updating centos" )
#!/usr/bin/env python3 from chibi.command import yum from chibi.command.echo import cowsay from chibi.file.snippets import inflate_dir from chibi.file import Chibi_file from chibi.command import command, systemctl file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "kibana\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "Starting install for kibana" ) yum.install( 'kibana' ) systemctl.enable( "kibana" ) systemctl.start( "kibana" ) file_check.append( version_to_check ) cowsay( "Ending install for kibana" )
#!/usr/bin/env python3 from chibi.command import yum, git, command from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir, join, exists, current_dir, cd cache_dir = inflate_dir('~/.cache') file_check_path = inflate_dir('~/provision_installed') file_check = Chibi_file(file_check_path) version_to_check = "ponysay\n".format(file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay("Starting install for ponysay") yum.install('texinfo') original_dir = current_dir() cd(cache_dir) ponysay_dir = join(cache_dir, 'ponysay') if not exists(ponysay_dir): git.clone('https://github.com/erkin/ponysay.git', ponysay_dir) cd(ponysay_dir) command('python3', './setup.py', 'install', '--freedom=partial') cd(original_dir) file_check.append(version_to_check)
from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "postgresql install\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "instalado postgresql" ) yum.install( "https://download.postgresql.org/pub/repos/yum/9.5/" "redhat/rhel-7-x86_64/pgdg-centos95-9.5-2.noarch.rpm" ) yum.install( 'postgresql95', 'postgresql95-server', 'postgresql95-libs', 'postgresql95-contrib', 'postgresql95-devel' ) yum.install( 'postgis2_95-client' ) command( "/usr/pgsql-9.5/bin/postgresql95-setup", "initdb" ) #command( "postgresql-setup", "initdb" ) systemctl.start( "postgresql-9.5" ) systemctl.enable( "postgresql-9.5" ) cowsay( "termino de instalar postgresql" ) file_check.append( version_to_check )
#!/usr/bin/env python3 from chibi.command import yum, systemctl, rpm from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir('~/provision_installed') file_check = Chibi_file(file_check_path) version_to_check = "elasticsearch\n".format(file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay("Starting install for elasticsearch") rpm.rpm_import('https://artifacts.elastic.co/GPG-KEY-elasticsearch') yum.install('elasticsearch') systemctl.enable('elasticsearch.service') systemctl.start('elasticsearch.service') #command( # '/usr/share/elasticsearch/bin/plugin', 'install', # 'royrusso/elasticsearch-HQ' ) file_check.append(version_to_check) cowsay("Ending install for elasticsearch")
#!/usr/bin/env python3 from chibi.command import yum, command from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "java 1.8.0\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "Starting install for java" ) yum.install( 'java-1.8.0-openjdk.x86_64' ) file_check.append( version_to_check ) java_version = command( 'java', '-version', stdout='pipe' ) cowsay( "Ending install for java, the version is\n{}".format( java_version ) )
from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "postgresql install\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "install postgresql" ) yum.install( "https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm") #"https://download.postgresql.org/pub/repos/yum/9.6/redhat/rhel-7-x86_64/pgdg-centos96-9.6-3.noarch.rpm" ) yum.install( 'postgresql96', 'postgresql96-server', 'postgresql96-libs', 'postgresql96-contrib', 'postgresql96-devel' ) yum.install( 'postgis2_96-client' ) command( "/usr/pgsql-9.6/bin/postgresql96-setup", "initdb" ) #command( "postgresql-setup", "initdb" ) systemctl.start( "postgresql-9.6" ) systemctl.enable( "postgresql-9.6" ) cowsay( "end install postgresql" ) file_check.append( version_to_check )
#!/usr/bin/env python3 from chibi.command import yum, systemctl, command from chibi.command.echo import cowsay from chibi.file.snippets import inflate_dir from chibi.file import Chibi_file file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "redis\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "instalado redis" ) yum.install( 'redis' ) systemctl.start( "redis" ) systemctl.enable( "redis" ) cowsay( "termino de instalar redis" ) result, error, return_code = command( 'redis-cli', 'ping', stdout='pipe' ) cowsay( "redis ping say: {}".format( result ) ) file_check.append( version_to_check )
#!/usr/bin/env python3 from chibi.command import yum from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir('~/provision_installed') file_check = Chibi_file(file_check_path) version_to_check = "essential\n".format(file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay("Starting install for essential") yum.install('bash-completion', 'bash-completion-extras', 'texinfo', 'vim', 'ruby', 'git', 'kernel-headers', 'kernel-devel', 'htop') file_check.append(version_to_check) cowsay("Ending install for essential")
#!/usr/bin/env python3 from chibi.command import yum, command from chibi.command.echo import cowsay from chibi.file import Chibi_file from chibi.file.snippets import inflate_dir file_check_path = inflate_dir('~/provision_installed') file_check = Chibi_file(file_check_path) version_to_check = "java\n".format(file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay("Starting install for java") yum.install('java-1.8.0-openjdk.x86_64') file_check.append(version_to_check) java_version = command('java', '-version', stdout='pipe') cowsay("Ending install for java, the version is\n{}".format(java_version))
#!/usr/bin/env python3 from chibi.command import yum, systemctl, rpm from chibi.command.echo import cowsay from chibi.file.snippets import inflate_dir from chibi.file import Chibi_file file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "elasticsearch 6\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "Starting install for elasticsearch" ) rpm.rpm_import( 'https://artifacts.elastic.co/GPG-KEY-elasticsearch' ) yum.install( 'elasticsearch' ) systemctl.enable( 'elasticsearch.service' ) systemctl.start( 'elasticsearch.service' ) #command( # '/usr/share/elasticsearch/bin/plugin', 'install', # 'royrusso/elasticsearch-HQ' ) file_check.append( version_to_check ) cowsay( "Ending install for elasticsearch" )
#!/usr/bin/env python3 from chibi.command import yum, command, systemctl from chibi.net import download from chibi.command.echo import cowsay from chibi.file.snippets import inflate_dir, cd from chibi.file import Chibi_file cowsay( "instalasion daskboards de kibana" ) cd( '/tmp/' ) download( 'https://download.elastic.co/beats/dashboards/beats-dashboards-1.1.0.zip', file_name='beats-dashboards.zip' ) yum.install( 'unzip' ) command( 'unzip', 'beats-dashboards.zip' ) cd ( 'beats-dashboards' ) command( './load.sh', '-l', 'waifus:80' ) cowsay( "fin de instalasion de los dashboards de kibana" )
#!/usr/bin/env python3 from chibi.command import yum from chibi.command.echo import cowsay from chibi.file.snippets import inflate_dir from chibi.file import Chibi_file file_check_path = inflate_dir( '~/provision_installed' ) file_check = Chibi_file( file_check_path ) version_to_check = "essential 1\n".format( file=__file__, ) if __name__ == "__main__" and not version_to_check in file_check: cowsay( "Starting install for essential" ) yum.install( 'bash-completion', 'bash-completion-extras', 'texinfo', 'vim', 'ruby', 'git', 'kernel-headers', 'kernel-devel', 'htop' ) file_check.append( version_to_check ) cowsay( "Ending install for essential" )
#!/usr/bin/env python3 from chibi.command import yum, echo echo.cowsay( "start updating centos" ) yum.update() yum.install( 'epel-release' ) echo.cowsay( "end updating centos" )