From 5c47193f9a1ab2f70dd4005f07a299d9a87ce928 Mon Sep 17 00:00:00 2001 From: Aravindan Thulasinathan Date: Thu, 20 Mar 2025 22:15:48 -0700 Subject: [PATCH] upload to codeartifact --- .github/workflows/python-app.yml | 8 ++++++++ Makefile | 2 ++ code_crypt/metadata.py | 2 +- requirements.txt | 2 ++ 4 files changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml index 23efc47..a75ce4f 100644 --- a/.github/workflows/python-app.yml +++ b/.github/workflows/python-app.yml @@ -29,3 +29,11 @@ jobs: - name: Test run: | make test + - name: Upload to Codeartifact + run: | + export TWINE_USERNAME=aws + export TWINE_PASSWORD=`aws codeartifact get-authorization-token --domain nextdoor --query authorizationToken --output text --region us-west-2 --duration 900` + export TWINE_REPOSITORY_URL=`aws codeartifact get-repository-endpoint --domain nextdoor --domain-owner 364942603424 --region us-west-2 --repository dev-arvi --format pypi --query repositoryEndpoint --output text` + python setup.py sdist bdist_wheel + twine upload dist/* + diff --git a/Makefile b/Makefile index 00d99d0..8cb13ff 100644 --- a/Makefile +++ b/Makefile @@ -25,6 +25,8 @@ test: venv install: python setup.py install +upload: + ############################################################################### # Development Environment Setup ############################################################################### diff --git a/code_crypt/metadata.py b/code_crypt/metadata.py index 1b1f298..d72673f 100644 --- a/code_crypt/metadata.py +++ b/code_crypt/metadata.py @@ -13,5 +13,5 @@ # Copyright 2017 Nextdoor.com, Inc -__version__ = "0.1.5" +__version__ = "0.1.6" __desc__ = "Code Crypt" diff --git a/requirements.txt b/requirements.txt index 84eb978..1d73055 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,4 @@ boto3>=1.17.106,<2.0.0 cryptography>=36.0.2 # ugh... they use major versions mainly now +twine==6.1.0 +awscli==1.38.17 \ No newline at end of file