Ticket #55229: _ansible.patch
File _ansible.patch, 9.0 KB (added by adfernandes (Andrew Fernandes), 7 years ago) |
---|
-
new file python/ansible_select/Portfile
diff --git a/python/ansible_select/Portfile b/python/ansible_select/Portfile new file mode 100644 index 0000000000..e8895f0e8c
- + 1 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 2 3 PortSystem 1.0 4 PortGroup select 1.0 5 6 name ansible_select 7 version 0.1 8 categories sysutils 9 platforms darwin 10 supported_archs noarch 11 license BSD 12 maintainers {adfernandes @adfernandes} openmaintainer 13 14 description Common files for selecting the default Ansible version 15 long_description This port installs files that allow 'port select' to \ 16 create links to the preferred default version of Ansible.\ 17 18 homepage http://www.macports.org 19 20 distfiles 21 use_configure no 22 build { } 23 24 destroot { 25 select::install ansible ${filespath}/base 26 select::install ansible ${filespath}/none 27 } 28 29 livecheck.type none -
new file python/ansible_select/files/base
diff --git a/python/ansible_select/files/base b/python/ansible_select/files/base new file mode 100644 index 0000000000..f8c7dfd804
- + 1 bin/ansible 2 bin/ansible-config 3 bin/ansible-connection 4 bin/ansible-console 5 bin/ansible-doc 6 bin/ansible-galaxy 7 bin/ansible-inventory 8 bin/ansible-playbook 9 bin/ansible-pull 10 bin/ansible-vault -
new file python/ansible_select/files/none
diff --git a/python/ansible_select/files/none b/python/ansible_select/files/none new file mode 100644 index 0000000000..b63a30ca5e
- + 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - -
new file python/py-ansible/Portfile
diff --git a/python/py-ansible/Portfile b/python/py-ansible/Portfile new file mode 100644 index 0000000000..7bcd89c9f4
- + 1 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 2 3 PortSystem 1.0 4 PortGroup python 1.0 5 PortGroup select 1.0 6 7 name py-ansible 8 version 2.4.1.0 9 license BSD 10 11 categories-append sysutils 12 platforms darwin 13 supported_archs noarch 14 15 maintainers {adfernandes @adfernandes} blair gmail.com:pedro.salgado 16 17 master_sites pypi:a/ansible 18 homepage https://github.com/ansible/ansible 19 description SSH-based configuration management and deployment system 20 21 distname ansible-${version} 22 checksums rmd160 75fe5ce2b60442ef9eb345fbd3fd9e356860f026 \ 23 sha256 da61afb29cc5bd6bc4737a2da06e673fb6fccc3ae2685130d19ab3a8e404fb6a 24 25 long_description \ 26 Ansible is a radically simple model-driven configuration \ 27 management, multi-node deployment, and remote task execution \ 28 system. Ansible works over SSH and does not require any software \ 29 or daemons to be installed on remote nodes. Extension modules can \ 30 be written in any language and are transferred to managed machines \ 31 automatically. 32 33 python.versions 27 35 36 34 35 36 if {${name} ne ${subport}} { 37 38 39 depends_lib-append port:py${python.version}-six \ 40 port:py${python.version}-paramiko \ 41 port:py${python.version}-httplib2 \ 42 port:py${python.version}-jinja2 \ 43 port:py${python.version}-yaml \ 44 port:py${python.version}-setuptools \ 45 port:py${python.version}-cryptography \ 46 port:ansible_select 47 48 depends_build-append port:asciidoc \ 49 port:libxslt \ 50 port:docbook-xsl 51 52 select.group ansible 53 select.file ${filespath}/py${python.version}-ansible 54 notes " 55 To make the Python ${python.branch} version of Ansible the one that is run\ 56 when you execute the commands without a version suffix, e.g. 'ansible', run: 57 58 port select --set ${select.group} [file tail ${select.file}] 59 " 60 61 62 livecheck.type none 63 64 } else { 65 66 livecheck.name ansible 67 68 } -
new file python/py-ansible/files/py27-ansible
diff --git a/python/py-ansible/files/py27-ansible b/python/py-ansible/files/py27-ansible new file mode 100644 index 0000000000..b262a2587a
- + 1 bin/ansible-2.7 2 bin/ansible-config-2.7 3 bin/ansible-connection-2.7 4 bin/ansible-console-2.7 5 bin/ansible-doc-2.7 6 bin/ansible-galaxy-2.7 7 bin/ansible-inventory-2.7 8 bin/ansible-playbook-2.7 9 bin/ansible-pull-2.7 10 bin/ansible-vault-2.7 -
new file python/py-ansible/files/py35-ansible
diff --git a/python/py-ansible/files/py35-ansible b/python/py-ansible/files/py35-ansible new file mode 100644 index 0000000000..401133e291
- + 1 bin/ansible-3.5 2 bin/ansible-config-3.5 3 bin/ansible-connection-3.5 4 bin/ansible-console-3.5 5 bin/ansible-doc-3.5 6 bin/ansible-galaxy-3.5 7 bin/ansible-inventory-3.5 8 bin/ansible-playbook-3.5 9 bin/ansible-pull-3.5 10 bin/ansible-vault-3.5 -
new file python/py-ansible/files/py36-ansible
diff --git a/python/py-ansible/files/py36-ansible b/python/py-ansible/files/py36-ansible new file mode 100644 index 0000000000..01777304c1
- + 1 bin/ansible-3.6 2 bin/ansible-config-3.6 3 bin/ansible-connection-3.6 4 bin/ansible-console-3.6 5 bin/ansible-doc-3.6 6 bin/ansible-galaxy-3.6 7 bin/ansible-inventory-3.6 8 bin/ansible-playbook-3.6 9 bin/ansible-pull-3.6 10 bin/ansible-vault-3.6 -
sysutils/ansible/Portfile
diff --git a/sysutils/ansible/Portfile b/sysutils/ansible/Portfile index 9ecec94d94..cc58cddda5 100644
a b 2 2 3 3 PortSystem 1.0 4 4 PortGroup python 1.0 5 PortGroup github 1.06 5 7 6 name ansible 8 7 epoch 1 9 8 categories sysutils 10 9 11 github.setup ${name} ${name} 2.3.2.0-1 v 12 version [string map {- .} ${version}] 13 revision 1 14 fetch.type git 10 replaced_by py-ansible 11 distfiles 12 13 version 2.3.2.0.1 14 revision 2 15 15 16 16 maintainers {adfernandes @adfernandes} blair gmail.com:pedro.salgado 17 17 18 license BSD 18 19 homepage https://github.com/ansible/ansible 19 20 description SSH-based configuration management and deployment system 20 21 long_description \ … … long_description \ 24 25 or daemons to be installed on remote nodes. Extension modules can \ 25 26 be written in any language and are transferred to managed machines \ 26 27 automatically. 27 license GPL-3+28 28 29 29 platforms darwin 30 30 supported_archs noarch 31 31 32 python.versions 27 33 34 depends_lib-append port:py${python.version}-six \ 35 port:py${python.version}-paramiko \ 36 port:py${python.version}-httplib2 \ 37 port:py${python.version}-jinja2 \ 38 port:py${python.version}-yaml \ 39 port:py${python.version}-setuptools \ 40 port:py${python.version}-crypto 41 42 depends_build-append port:asciidoc \ 43 port:libxslt \ 44 port:docbook-xsl 45 46 post-fetch { 47 # fetch submodules (https://github.com/ansible/ansible/issues/11199) 48 system -W "${worksrcpath}" "git submodule update --init" 49 } 50 51 patch { 52 fs-traverse f ${worksrcpath} { 53 if {[file isfile ${f}] && ![regexp {\.(bin|ico|png|eot|ttf|woff|reg|gz|zip)$} ${f} match] && ![regexp {\.git} ${f} match] && ![regexp {v2/test/test.yml} ${f} match]} { 54 reinplace -q "s#/etc/ansible#${prefix}/etc/ansible#g" ${f} 55 reinplace -q "s#/usr/share/ansible#${prefix}/share/ansible#g" ${f} 56 } 57 } 58 } 59 60 post-build { 61 system -W "${worksrcpath}" "make docs" 62 } 63 64 post-destroot { 65 # Documentation and examples. 66 xinstall -m 644 -W ${worksrcpath} README.md COPYING \ 67 ${destroot}${prefix}/share/doc/${name} 68 69 xinstall -m 755 -d ${destroot}${prefix}/share/doc/examples 70 xinstall -m 755 ${worksrcpath}/examples/ansible.cfg \ 71 ${destroot}${prefix}/share/doc/${name}/examples 72 xinstall -m 755 ${worksrcpath}/examples/hosts \ 73 ${destroot}${prefix}/share/doc/${name}/examples 74 75 # Man pages. 76 xinstall -m 755 {*}[glob ${worksrcpath}/docs/man/man1/*.1] \ 77 ${destroot}${prefix}/share/man/man1 78 79 # Install sample config and hosts file. 80 xinstall -m 755 -d ${destroot}${prefix}/etc/ansible 81 xinstall -b -m 755 ${worksrcpath}/examples/ansible.cfg \ 82 ${destroot}${prefix}/etc/ansible/ansible.cfg.default 83 xinstall -b -m 755 ${worksrcpath}/examples/hosts \ 84 ${destroot}${prefix}/etc/ansible/hosts.default 32 pre-configure { 33 ui_error "Please do not install this port since it has been replaced by 'py-ansible'." 34 ui_error "Both Python-2 and Python-3 are supporteed. Use 'sudo port uninstall ansible'" 35 ui_error "followed by 'sudo port install py{27|36}-ansible' to install the newest" 36 ui_error "version, then use 'sudo port select --set ansible py{27|36}-ansible' to" 37 ui_error "select the default Python runtime for Ansible." 38 return -code error 85 39 }