diff --git a/src/bdistrecipe/bdistrecipe.py b/src/bdistrecipe/bdistrecipe.py new file mode 100644 index 0000000000000000000000000000000000000000..1f637c15bbf824bfcd4ff2b7d88c0f7c8cef27c3 --- /dev/null +++ b/src/bdistrecipe/bdistrecipe.py @@ -0,0 +1,25 @@ +import os + +class Recipe: + def __init__(self, buildout, name, options): + options['created'] = "{}/dist/{}".format(options['path'], name + "-4.0.0a1.dev1.tar.bz2") + self.options = options + + def install(self): + self.options.created(self.options['created']) + home = os.getcwd() + + # cd into correct directory + os.chdir(self.options['path']) + # Run setup.py + os.system("conda run -n data python3 setup.py bdist") + os.chdir(home) + # Deploy conda package to builder + builder_path = "/home/builder.aoc.nrao.edu/content/conda/" + platform = "osx64" + os.system("scp {}/{} builder:{}".format(home, self.options['created'], builder_path + platform)) + os.system("ssh builder 'cd {} && conda index'".format(builder_path)) + + return self.options.created() + + update = install \ No newline at end of file diff --git a/src/bdistrecipe/setup.py b/src/bdistrecipe/setup.py new file mode 100644 index 0000000000000000000000000000000000000000..488a299c9d386cdbd33847a58537eb91ebdd13e5 --- /dev/null +++ b/src/bdistrecipe/setup.py @@ -0,0 +1,8 @@ +from setuptools import setup + +setup( + name='bdistrecipe', + version='0.1', + py_modules = ['bdistrecipe'], + entry_points = {"zc.buildout": ["default=bdistrecipe:Recipe"]} +) \ No newline at end of file diff --git a/src/condarecipe/condarecipe.py b/src/condarecipe/condarecipe.py new file mode 100644 index 0000000000000000000000000000000000000000..fe8bfd6fa0dc73223c5adf59a5d05053d2059f1d --- /dev/null +++ b/src/condarecipe/condarecipe.py @@ -0,0 +1,14 @@ +import os + +class Recipe: + def __init__(self, buildout, name, options): + options['created'] = "{}/envs/{}".format(options['path'], name + options['env']) + self.options = options + + def install(self): + self.options.created(self.options['created']) + os.system("source /opt/miniconda3/etc/profile.d/conda.sh && conda activate data") + + return self.options.created() + + update = install \ No newline at end of file diff --git a/src/condarecipe/setup.py b/src/condarecipe/setup.py new file mode 100644 index 0000000000000000000000000000000000000000..e912bcf0fba710b271acbeeab568589eb2c1df32 --- /dev/null +++ b/src/condarecipe/setup.py @@ -0,0 +1,8 @@ +from setuptools import setup + +setup( + name='condarecipe', + version='0.1', + py_modules = ['condarecipe'], + entry_points = {"zc.buildout": ["default=condarecipe:Recipe"]}, +) \ No newline at end of file diff --git a/support/conda/datafetcher/meta.yaml b/support/conda/datafetcher/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..b4c190ef4d202786285a827ecb6632da60ee9934 --- /dev/null +++ b/support/conda/datafetcher/meta.yaml @@ -0,0 +1,39 @@ +{% set name = "datafetcher" %} +{% set version = "4.0.0a1.dev1" %} + +package: + name: "{{ name|lower }}" + version: "{{ version }}" + +build: + entry_points: + - datafetcher = datafetcher.commands:main + script: python setup.py install + +source: + path: /Users/nhertz/data/apps/cli/executables/datafetcher + +requirements: + run: + - python + - pika==1.1.0 + - pycapo + - bs4 + - beautifulsoup4==4.9.1 + - lxml==4.3.2 + - psycopg2==2.8.5 + - pyinstaller + - pyopenssl=19.1.0 + - tox + +#test: +# requires: +# - pytest +# - pytest-runner +# commands: +# - pytest -x --showlocals + +about: + license: "GPL" + license_family: "GPL" + summary: "NRAO Archive Data Fetcher Script" diff --git a/support/conda/events/meta.yaml b/support/conda/events/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..cd0fddf4302cb72b0a54c3146e2a4d3af6890e2e --- /dev/null +++ b/support/conda/events/meta.yaml @@ -0,0 +1,25 @@ +{% set name = "events" %} +{% set version = "4.0.0a1.dev1" %} + +package: + name: "{{ name|lower }}" + version: "{{ version }}" + +source: + path: /Users/nhertz/data/shared/messaging/events + +build: + number: 0 + script: + - python setup.py install + +requirements: + run: + - python=3.8 + - pika + - pycapo + +about: + license: "GPL" + license_family: "GPL" + summary: "NRAO Archive Data Fetcher Script" diff --git a/support/conda/pycapo/meta.yaml b/support/conda/pycapo/meta.yaml index caab0fdcebc5c2becd975238084effec7d8b9c31..5163cca748c8ea60ab0bc0853722ce71dc233ecc 100644 --- a/support/conda/pycapo/meta.yaml +++ b/support/conda/pycapo/meta.yaml @@ -1,5 +1,5 @@ {% set name = "pycapo" %} -{% set version = "0.2.1.post1" %} +{% set version = "0.3.0" %} package: name: "{{ name|lower }}" @@ -7,7 +7,7 @@ package: source: url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz - sha256: 703002d913d4e38a4bcce7748674ef58d4fd63c9fd099316b4643a89955ff361 + sha256: 507d47278a66f2a67dc817e2dae533374ad0c8312aed7ab6e23e1b322baef5c6 build: number: 0