airbnb / knowledge-repo

A next-generation curated knowledge sharing platform for data scientists and other technical professions.
Apache License 2.0
5.48k stars 687 forks source link

upload images to S3 #301

Open ashwinks65 opened 7 years ago

ashwinks65 commented 7 years ago

Auto-reviewers: @NiharikaRay @matthewwardrop @earthmancash @danfrankj

Hi,

Could you please provide more information about uploading the images into S3. Also, more insight about these two class 'ExtractImages' and 'ExtractImagesToS3' and how to configure extract_images_to_s3.py file for our organization's cloud storage.

matthewwardrop commented 7 years ago

Hi @Ashwin501 ,

You should import (or copy/paste) the contents of the extract_images_to_s3.py into .knowledge_repo_config.py inside of your git knowledge repository. Then you just need to add 'extract_images_to_s3' to the postprocessors list inside of the same file. This processor will then be applied to every subsequent knowledge post that is added to the repository.

Does that help?

M

ashwinks65 commented 7 years ago

@Matthewwardrop thanks a lot it really helped.

I am having issue regarding "Submitting knowledge". I'm trying to submit the knowledge to remote repository but getting following error.

Traceback (most recent call last): File "C:\Program Files\JetBrains\PyCharm Community Edition 2017.1.4\helpers\pydev\pydevd.py", line 1591, in globals = debugger.run(setup['file'], None, None, is_module) File "C:\Program Files\JetBrains\PyCharm Community Edition 2017.1.4\helpers\pydev\pydevd.py", line 1018, in run pydev_imports.execfile(file, globals, locals) # execute the script File "C:/Users/212629680/Desktop/Knowledge-master/scripts/knowledge_repo", line 263, in repo.submit(path=args.path) File "C:/Users/212629680/Desktop/Knowledge-master/scripts..\knowledge_repo\repository.py", line 282, in submit return self._submit(self._kp_path(path)) File "C:/Users/212629680/Desktop/Knowledge-master/scripts..\knowledge_repo\repositories\gitrepository.py", line 373, in _submit raise RuntimeError("Could not find remote repository {} into which this branch should be submitted.".format(self.config.remote_name)) RuntimeError: Could not find remote repository origin into which this branch should be submitted.

Please suggest how to pass remote repository URL as a parameter.

Thanks Ashwin

ashwinks65 commented 7 years ago

INFO:alembic.runtime.migration:Context impl SQLiteImpl. INFO:alembic.runtime.migration:Will assume non-transactional DDL.

Please suggest how we can run the flask application with knowledge repo.

Many Thanks Ashwin