jbhoorasingh / photobooth-app-shareservice

This project is a Python implementation of the PhotoBooth-App ShareService. It provides functionality to upload and save photos to an S3 bucket, replacing the original PHP implementation with a Python-based approach.
1 stars 0 forks source link

How to install #1

Open WebfinityDesign opened 3 months ago

WebfinityDesign commented 3 months ago

I tried to install this because it seems like a nice project but I don't know how to install it. I do have an AWS account but I don't know how to get the S3 bucket endpoint. I assume this application has to be installed on the server. Am I right?

jbhoorasingh commented 3 months ago

The application can run on a server, in the next month I will wrap up the containerization of the app so you should be able to to pull directly from Docker hub.

For AWS the first thing you need to do is create a S3 Bucket, then you can create a identity and generate a access key for that identity: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html

Alternatively, you can use Digital Ocean Spaces as the object store, it's a simpler to get started in my opinion and cheaper.

Step 1: Create Digital Ocean Account

  1. Head over to Digital Ocean and sign up for an account, if you use this referral link you will get $200 credit (i will get 25) https://www.digitalocean.com/?refcode=0fea2173d2fd&utm_campaign=Referral_Invite&utm_medium=Referral_Program&utm_source=badge

Step 2: Create a space/bucket

  1. Create a Space, make note of the name and the region you selected
  2. Get Access Key for Bucket

Step 3: Deploy Droplet/Server

  1. Pick a OS you are comfortable with. Getting Started with Droplet
  2. Install Python (at least 3.10)
  3. Follow instructions in README.md
WebfinityDesign commented 3 months ago

I've been fumbling with this last night. I already had an AWS account I didn't use. With some Youtube I managed to make a bucket, I do have the keys, but I'm not sure where to get the endpoint and the region. I tried something, but now, when I try to share a photo I get: Cannot reach ss.photobooth.dev.local. Which seems to me a URL to be used on a local network, am I right? I installed all on the server. I am wondering: is there a part I should install on the photobooth? Maybe it is just because of the endpoint or region not being correct

jbhoorasingh commented 3 months ago

Regarding the endpoint, documentation is here. It would be s3.Region.amazonaws.com. The region is the AWS region you deployed the resource (look for something like us-east1/us-west2).

Need to update the shareservice url, in the README.md:

The url would be the service url will be http://IP_OF_YOUR_EC2_INSTANCE:8080/pba-shareservice. You also need to update the security group associated to your EC2 to allow incoming connections to 8080

WebfinityDesign commented 3 months ago

Thank you. I will try it later. For now I'm trying the dl.php option. That seems to be the quickest way to get it working. I want to have it working asap for an upcoming birthday.

WebfinityDesign commented 2 months ago

I got it working now, but I need to be on the same network as the booth. Isn't it possible to adjust the share url so it will directly download from the S3 bucket so you can just download it over any internet connection?