forked from amundsen-io/amundsen
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: shared dependencies unification (amundsen-io#1163)
* unify_deps | 🎉 Initial commit. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ♻️ Refactoring code. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🚨 Removing linter warnings. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🚨 Removing linter warnings. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🚨 Removing linter warnings. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ✅ Adding tests. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ⬆️ Upgrading dependencies. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ✨ Introducing new features. (run tests when reqs change) Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ♻️ Refactoring code. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 💡 Documenting source code. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 📝 Writing docs. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 💄 Updating the UI and style files. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ⬆️ Upgrading dependencies. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | ♻️ Refactoring code. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 💡 Documenting source code. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🚨 Removing linter warnings. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 👌 Updating code due to code review changes. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🎉 Initial commit. Signed-off-by: mgorsk1 <[email protected]> * unify_deps | 🐛 Fixing a bug. Signed-off-by: mgorsk1 <[email protected]> Co-authored-by: Dorian Johnson <[email protected]>
- Loading branch information
1 parent
b6f3a59
commit 4165e11
Showing
59 changed files
with
309 additions
and
397 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
** | ||
!frontend | ||
!metadata | ||
!search | ||
!requirements*txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
ARG METADATASERVICE_BASE | ||
ARG SEARCHSERVICE_BASE | ||
|
||
FROM node:12-slim as node-stage | ||
WORKDIR /app/amundsen_application/static | ||
|
||
COPY ./frontend/amundsen_application/static/package.json /app/amundsen_application/static/package.json | ||
COPY ./frontend/amundsen_application/static/package-lock.json /app/amundsen_application/static/package-lock.json | ||
RUN npm install | ||
|
||
COPY ./frontend/amundsen_application/static/ /app/amundsen_application/static/ | ||
RUN npm rebuild node-sass | ||
RUN npm run dev-build | ||
|
||
COPY ./frontend /app | ||
|
||
FROM python:3.7-slim | ||
WORKDIR /app | ||
|
||
COPY ./frontend /app | ||
COPY requirements-dev.txt /app/requirements-dev.txt | ||
COPY requirements-common.txt /app/requirements-common.txt | ||
|
||
COPY --from=node-stage /app /app | ||
|
||
RUN pip3 install -e . | ||
|
||
ENTRYPOINT [ "python3" ] | ||
CMD [ "amundsen_application/wsgi.py" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
FROM python:3.7-slim | ||
WORKDIR /app | ||
RUN pip3 install gunicorn | ||
|
||
COPY ./search/ /app/ | ||
COPY requirements-dev.txt /app/requirements-dev.txt | ||
COPY requirements-common.txt /app/requirements-common.txt | ||
RUN pip3 install -e . | ||
|
||
CMD [ "python3", "search_service/search_wsgi.py" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
include requirements.txt | ||
|
||
global-include requirements-*.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,3 +17,7 @@ mypy: | |
|
||
|
||
test: test_unit lint mypy | ||
|
||
.PHONY: install_deps | ||
install_deps: | ||
pip3 install -e ".[all]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../requirements-common.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../requirements-dev.txt |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,39 @@ | ||
# Copyright Contributors to the Amundsen project. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
import os | ||
|
||
from setuptools import find_packages, setup | ||
|
||
__version__ = '0.13.0' | ||
|
||
requirements_path = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'requirements-common.txt') | ||
with open(requirements_path) as requirements_file: | ||
requirements_common = requirements_file.readlines() | ||
|
||
requirements_path = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'requirements-dev.txt') | ||
with open(requirements_path) as requirements_file: | ||
requirements_dev = requirements_file.readlines() | ||
|
||
# avoid circular references | ||
requirements_common = [r for r in requirements_common if not r.startswith('amundsen-common')] | ||
|
||
all_deps = requirements_common + requirements_dev | ||
|
||
setup( | ||
name='amundsen-common', | ||
version=__version__, | ||
description='Common code library for Amundsen', | ||
long_description=open('README.md').read(), | ||
long_description_content_type='text/markdown', | ||
url='https://github.com/amundsen-io/amundsencommon', | ||
url='https://github.com/amundsen-io/amundsen/tree/main/common', | ||
maintainer='Amundsen TSC', | ||
maintainer_email='[email protected]', | ||
packages=find_packages(exclude=['tests*']), | ||
install_requires=[ | ||
# Packages in here should rarely be pinned. This is because these | ||
# packages (at the specified version) are required for project | ||
# consuming this library. By pinning to a specific version you are the | ||
# number of projects that can consume this or forcing them to | ||
# upgrade/downgrade any dependencies pinned here in their project. | ||
# | ||
# Generally packages listed here are pinned to a major version range. | ||
# | ||
# e.g. | ||
# Python FooBar package for foobaring | ||
# pyfoobar>=1.0, <2.0 | ||
# | ||
# This will allow for any consuming projects to use this library as | ||
# long as they have a version of pyfoobar equal to or greater than 1.x | ||
# and less than 2.x installed. | ||
'Flask>=1.0.2', | ||
'attrs>=19.0.0', | ||
'marshmallow>=3.0', | ||
'marshmallow3-annotations>=1.0.0' | ||
], | ||
install_requires=requirements_common, | ||
extras_require={ | ||
'all': all_deps, | ||
'dev': requirements_dev | ||
}, | ||
python_requires=">=3.6", | ||
package_data={'amundsen_common': ['py.typed']}, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
include requirements.txt | ||
|
||
global-include requirements-dev.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../requirements-dev.txt |
Oops, something went wrong.