diff options
author | Danilo G. Baio <dbaio@FreeBSD.org> | 2019-12-05 00:52:52 +0000 |
---|---|---|
committer | Danilo G. Baio <dbaio@FreeBSD.org> | 2019-12-05 00:52:52 +0000 |
commit | 13bac1c2997c2ad387a5e295dbdb75b7bfe04cbe (patch) | |
tree | fdec02a648351cc7a1ce566d21104c99bf912615 /sysutils/py-azure-cli | |
parent | f080503f057f286dd74ea4cf1c37106ddb26990c (diff) | |
download | ports-13bac1c2997c2ad387a5e295dbdb75b7bfe04cbe.tar.gz ports-13bac1c2997c2ad387a5e295dbdb75b7bfe04cbe.zip |
sysutils/py-azure-cli: Add experimental support for azcopy
Azcopy binary is not available officially for FreeBSD and even if you have
built it manually, azure-cli won't find/run it.
This patch add FreeBSD as an available platform and now users can build
and install azcopy manually to work with azure-cli.
More info at https://wiki.freebsd.org/Ports/sysutils/py-azure-cli
PR: 242391
Submitted by: cem
Notes
Notes:
svn path=/head/; revision=519057
Diffstat (limited to 'sysutils/py-azure-cli')
-rw-r--r-- | sysutils/py-azure-cli/Makefile | 1 | ||||
-rw-r--r-- | sysutils/py-azure-cli/files/patch-azure_cli_command__modules_storage_azcopy_util.py | 20 |
2 files changed, 21 insertions, 0 deletions
diff --git a/sysutils/py-azure-cli/Makefile b/sysutils/py-azure-cli/Makefile index ca359a9fdbc2..cf139361f20b 100644 --- a/sysutils/py-azure-cli/Makefile +++ b/sysutils/py-azure-cli/Makefile @@ -2,6 +2,7 @@ PORTNAME= azure-cli PORTVERSION= 2.0.77 +PORTREVISION= 1 CATEGORIES= sysutils python MASTER_SITES= CHEESESHOP PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} diff --git a/sysutils/py-azure-cli/files/patch-azure_cli_command__modules_storage_azcopy_util.py b/sysutils/py-azure-cli/files/patch-azure_cli_command__modules_storage_azcopy_util.py new file mode 100644 index 000000000000..676bcf4e35a4 --- /dev/null +++ b/sysutils/py-azure-cli/files/patch-azure_cli_command__modules_storage_azcopy_util.py @@ -0,0 +1,20 @@ +--- azure/cli/command_modules/storage/azcopy/util.py.orig 2019-12-04 23:30:55 UTC ++++ azure/cli/command_modules/storage/azcopy/util.py +@@ -41,6 +41,8 @@ class AzCopy(object): + file_url = base_url.format('linux', 'tar.gz') + elif self.system == 'Darwin': + file_url = base_url.format('darwin', 'zip') ++ elif self.system == 'FreeBSD': ++ raise CLIError('Azcopy ({}) binary not available, follow instructions at https://wiki.freebsd.org/Ports/sysutils/py-azure-cli'.format(self.system)) + else: + raise CLIError('Azcopy ({}) does not exist.'.format(self.system)) + try: +@@ -163,7 +165,7 @@ def _get_default_install_location(): + if not home_dir: + return None + install_location = os.path.join(home_dir, r'.azcopy\azcopy.exe') +- elif system in ('Linux', 'Darwin'): ++ elif system in ('Linux', 'Darwin', 'FreeBSD'): + install_location = os.path.expanduser(os.path.join('~', 'bin/azcopy')) + else: + install_location = None |