Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove debian targets from Makefile #136

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 2 additions & 38 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,49 +11,13 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
UID:=`id -u`
GID:=`id -g`
ITERATION=yelp1

.PHONY: test tests coverage clean


.PHONY: test
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

curious, what does .PHONY do exactly?

test:
tox

tests: test
coverage: test

itest_%: package_%
docker run -h fake.docker.hostname -v $(CURDIR):/work:rw docker-dev.yelpcorp.com/$*_yelp /bin/bash -c "/work/tests/ubuntu.sh"
docker run -v $(CURDIR):/work:rw docker-dev.yelpcorp.com/$*_yelp chown -R $(UID):$(GID) /work

package_%:
mkdir -p dist
docker run \
-h fake.docker.hostname \
-v $(CURDIR):/work:rw \
docker-dev.yelpcorp.com/$*_pkgbuild \
/bin/bash -c 'cd /work && \
fpm --force \
-s python -t deb \
-m "Compute Infrastructure <[email protected]>" \
--deb-user "root" --deb-group "root" \
--python-pypi "https://pypi.yelpcorp.com/simple" \
--python-install-lib "/usr/lib/python2.7/dist-packages" \
--python-install-bin "/usr/bin" \
--python-install-data "/usr" \
--no-python-dependencies \
--depends "python-yaml > 3.0" \
--deb-no-default-config-files \
--iteration="$(ITERATION)" . && \
mv *.deb dist/ \
'
docker run -v $(CURDIR):/work:rw docker-dev.yelpcorp.com/$*_yelp chown -R $(UID):$(GID) /work

venv: requirements.txt setup.py tox.ini
tox -e venv

.PHONY: clean
clean:
rm -rf .cache
rm -rf dist/
Expand Down
9 changes: 3 additions & 6 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
# Coverage==5.0 fails with `Safety level may not be changed inside a transaction`
# on python 3.6.0 (xenial) (https://github.com/nedbat/coveragepy/issues/703)
coverage<5
coverage
mock
mypy
pre-commit==1.21.0
pre-commit
pytest
types-PyYAML
# To resolve the error: types-requests 2.31.0.6 has requirement urllib3>=2, but you'll have urllib3 1.26.15 which is incompatible.
types-requests==2.31.0.5
types-requests
5 changes: 0 additions & 5 deletions requirements.txt

This file was deleted.

105 changes: 0 additions & 105 deletions tests/ubuntu.sh

This file was deleted.

3 changes: 0 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
[tox]
envlist = py37
tox_pip_extensions_ext_pip_custom_platform = true
tox_pip_extensions_ext_venv_update = true

[testenv]
deps =
-rrequirements-dev.txt
-rrequirements.txt
commands=
mypy service_configuration_lib
coverage erase
Expand Down
Loading