-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #48 from cancervariants/eb-working
Elastic Beanstalk Deployment
- Loading branch information
Showing
18 changed files
with
159 additions
and
74 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,23 @@ | ||
container_commands: | ||
00_export_eb_env_var: | ||
command: "export $(cat /opt/elasticbeanstalk/deployment/env | xargs)" | ||
01_install_awscli: | ||
command: "yum install -y awscli" | ||
02_install_unzip: | ||
command: "yum install -y unzip" | ||
03_s3_download: | ||
command: "aws s3 cp s3://${AWS_BUCKET_NAME}/${AWS_SEQREPO_OBJECT} ./variant/data/seqrepo.zip --region us-east-2" | ||
04_unzip_seqrepo: | ||
command: "unzip ./variant/data/seqrepo.zip -d ./variant/data" | ||
05_seqrepo_permission: | ||
command: "chmod -R 777 ./variant/data/seqrepo" | ||
06_macosx_permission: | ||
command: "chmod -R +wr ./variant/data/__MACOSX" | ||
07_seqrepo_zip_permission: | ||
command: "chmod +wr ./variant/data/seqrepo.zip" | ||
08_remove_macosx: | ||
command: "rm -R ./variant/data/__MACOSX" | ||
09_remove_seqrepo_zip: | ||
command: "rm ./variant/data/seqrepo.zip" | ||
10_data_permission: | ||
command: "chmod -R +wrx ./variant/data" |
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 |
---|---|---|
@@ -1 +1 @@ | ||
web: gunicorn -w 4 -k uvicorn.workers.UvicornWorker main:app | ||
web: gunicorn -k uvicorn.workers.UvicornWorker main:app |
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 |
---|---|---|
@@ -1,29 +1,34 @@ | ||
"""Module for testing Protein Substitution Translator.""" | ||
"""Module for testing amino acid Substitution Translator.""" | ||
import unittest | ||
from variant.classifiers import AminoAcidSubstitutionClassifier | ||
from variant.translators import AminoAcidSubstitution | ||
from variant.validators import AminoAcidSubstitution as AASUB_V | ||
from .translator_base import TranslatorBase | ||
from variant.tokenizers import GeneSymbol | ||
from variant.tokenizers.caches import GeneSymbolCache, AminoAcidCache | ||
from variant.data_sources import SeqRepoAccess, TranscriptMappings | ||
from variant import SEQREPO_DATA_PATH, TRANSCRIPT_MAPPINGS_PATH | ||
|
||
|
||
class TestAminoAcidSubstitutionTranslator(TranslatorBase, unittest.TestCase): | ||
"""A class to test the Protein Substitution Translator.""" | ||
"""A class to test the amino acid Substitution Translator.""" | ||
|
||
def classifier_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return amino acid substitution instance.""" | ||
return AminoAcidSubstitutionClassifier() | ||
|
||
def validator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return amino acid substitution instance.""" | ||
return AASUB_V(SeqRepoAccess(SEQREPO_DATA_PATH), | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH)) | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH), | ||
GeneSymbol(GeneSymbolCache()), | ||
AminoAcidCache() | ||
) | ||
|
||
def translator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return amino acid substitution instance.""" | ||
return AminoAcidSubstitution() | ||
|
||
def fixture_name(self): | ||
"""Return the fixture name for protein substitution.""" | ||
"""Return the fixture name for amino acid substitution.""" | ||
return 'amino_acid_substitution' |
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,29 +1,34 @@ | ||
"""Module for testing Protein Substitution Translator.""" | ||
"""Module for testing polypeptide truncation Translator.""" | ||
import unittest | ||
from variant.classifiers import PolypeptideTruncationClassifier | ||
from variant.translators import PolypeptideTruncation | ||
from variant.validators import PolypeptideTruncation as PT_V | ||
from .translator_base import TranslatorBase | ||
from variant.tokenizers import GeneSymbol | ||
from variant.tokenizers.caches import GeneSymbolCache, AminoAcidCache | ||
from variant.data_sources import SeqRepoAccess, TranscriptMappings | ||
from variant import SEQREPO_DATA_PATH, TRANSCRIPT_MAPPINGS_PATH | ||
|
||
|
||
class TestPolypeptideTruncationTranslator(TranslatorBase, unittest.TestCase): | ||
"""A class to test the Protein Substitution Translator.""" | ||
"""A class to test the polypeptide truncation Translator.""" | ||
|
||
def classifier_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return polypeptide truncation instance.""" | ||
return PolypeptideTruncationClassifier() | ||
|
||
def validator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return polypeptide truncation instance.""" | ||
return PT_V(SeqRepoAccess(SEQREPO_DATA_PATH), | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH)) | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH), | ||
GeneSymbol(GeneSymbolCache()), | ||
AminoAcidCache() | ||
) | ||
|
||
def translator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return polypeptide truncation instance.""" | ||
return PolypeptideTruncation() | ||
|
||
def fixture_name(self): | ||
"""Return the fixture name for protein substitution.""" | ||
return 'amino_acid_substitution' | ||
"""Return the fixture name for polypeptide truncation.""" | ||
return 'polypeptide_truncation' |
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,29 +1,34 @@ | ||
"""Module for testing Protein Substitution Translator.""" | ||
"""Module for testing Silent Mutation Translator.""" | ||
import unittest | ||
from variant.classifiers import SilentMutationClassifier | ||
from variant.translators import SilentMutation | ||
from variant.validators import SilentMutation as SM_V | ||
from .translator_base import TranslatorBase | ||
from variant.tokenizers import GeneSymbol | ||
from variant.tokenizers.caches import GeneSymbolCache, AminoAcidCache | ||
from variant.data_sources import SeqRepoAccess, TranscriptMappings | ||
from variant import SEQREPO_DATA_PATH, TRANSCRIPT_MAPPINGS_PATH | ||
|
||
|
||
class TestAminoAcidSubstitutionTranslator(TranslatorBase, unittest.TestCase): | ||
"""A class to test the Protein Substitution Translator.""" | ||
class TestSilentMutationTranslator(TranslatorBase, unittest.TestCase): | ||
"""A class to test the silent mutation Translator.""" | ||
|
||
def classifier_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return silent mutation instance.""" | ||
return SilentMutationClassifier() | ||
|
||
def validator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return silent mutation instance.""" | ||
return SM_V(SeqRepoAccess(SEQREPO_DATA_PATH), | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH)) | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH), | ||
GeneSymbol(GeneSymbolCache()), | ||
AminoAcidCache() | ||
) | ||
|
||
def translator_instance(self): | ||
"""Return protein substitution instance.""" | ||
"""Return silent mutation instance.""" | ||
return SilentMutation() | ||
|
||
def fixture_name(self): | ||
"""Return the fixture name for protein substitution.""" | ||
return 'amino_acid_substitution' | ||
"""Return the fixture name for silent mutation.""" | ||
return 'silent_mutation' |
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,24 +1,28 @@ | ||
"""Module for testing Amino Acid Substitution Validator.""" | ||
"""Module for testing Polypeptide Truncation Validator.""" | ||
import unittest | ||
from variant.validators import PolypeptideTruncation | ||
from variant.classifiers import PolypeptideTruncationClassifier | ||
from .validator_base import ValidatorBase | ||
from variant.tokenizers import GeneSymbol | ||
from variant.tokenizers.caches import GeneSymbolCache, AminoAcidCache | ||
from variant.data_sources import TranscriptMappings, SeqRepoAccess | ||
from variant import SEQREPO_DATA_PATH, TRANSCRIPT_MAPPINGS_PATH | ||
|
||
|
||
class TestPolypeptideTruncationValidator(ValidatorBase, unittest.TestCase): | ||
"""A class to test the Protein Substitution Validator.""" | ||
"""A class to test the Polypeptide Truncation Validator.""" | ||
|
||
def validator_instance(self): | ||
"""Return amino acid substitution instance.""" | ||
"""Return Polypeptide Truncation instance.""" | ||
return PolypeptideTruncation(SeqRepoAccess(SEQREPO_DATA_PATH), | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH)) # noqa: E501 | ||
TranscriptMappings(TRANSCRIPT_MAPPINGS_PATH), # noqa: E501 | ||
GeneSymbol(GeneSymbolCache()), | ||
AminoAcidCache()) | ||
|
||
def classifier_instance(self): | ||
"""Return the protein substitution classifier instance.""" | ||
"""Return the Polypeptide Truncation classifier instance.""" | ||
return PolypeptideTruncationClassifier() | ||
|
||
def fixture_name(self): | ||
"""Return the fixture name for protein substitution.""" | ||
"""Return the fixture name for Polypeptide Truncation.""" | ||
return 'polypeptide_truncation' |
Oops, something went wrong.