Skip to content

create a versatile file format conversion tool hosted on the AWS Cloud.

Notifications You must be signed in to change notification settings

sankalpx5/docx-to-pdf-convertor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

File Wizard

An open-source file conversion webapp built with ReactJs, Python
and AWS for the HTTP API, Lambda functions and S3 object storage.
Converts .docx files to .pdf

Features

  • Website

    • ReactJs App Router
    • Amazon Web Services for backend functionality
    • Support for HTTP API, S3 File Storage, and Lambda functions
    • Edge runtime-ready
  • AWS Infrastructure

Overview

image

A static site is hosted on S3 with a document upload form. We use API Gateway to create an API which makes a GET request to a Lambda function after the user clicks Upload File on the form.

The API sends a presigned bucket URL for the uploads-bucket. The site then automatically conducts a PUT request to the same bucket with the .docx file data.

Another Lambda function is configured to listen for PUT Object events in the S3 uploads-bucket. It parses the event record for file name and sends a POST request to the Python Flask App performing the document conversion.

An EC2 instance is deployed with an Ubuntu OS image. A python script is setup to run as a background process.

The python microservice converts documents using pandoc package and is exposed as an API using Flask listening for POST requests on a specified port. It downloads and saves the specified file with its ID, uploads the converted file to the output-bucket on S3 and performs cleanup for files saved during runtime.

The static site returns the download link for the converted file from the output-bucket.

About

create a versatile file format conversion tool hosted on the AWS Cloud.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published