Skip to content

josepsoares/video-render-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Golang Video Render API

Golang Docker FFMPEG

About

A somewhat simple golang REST API with the fiber framework with routes which process video and audio using the free and open-source software ffmpeg.

Requirements

Features

  • Concat videos (supports templates with a pre-determined structure) into a single video
  • Transcode, downscale videos
  • Convert image(s) to video(s) with a specific duration
  • Generate thumbnail from a specific time frame of a video
  • Executable tests of the features mentioned above

Development/Deploy

With Docker

$ docker image build

docker image building documentation

Without Docker

eg. linux (eg. ubuntu)

$ sudo apt update && sudo apt upgrade -y

### ffmpeg installation
$ sudo apt install ffmpeg

### go installation
$ cd ~
$ curl -OL https://golang.org/dl/go1.19.1.linux-amd64.tar.gz
$ sudo tar -C /usr/local -xvf go1.19.1.linux-amd64.tar.gz
$ sudo nano ~/.profile
# then, add the following information to the end of your file:
export PATH=$PATH:/usr/local/go/bin
$ source ~/.profile
# check if the installation is complete without problems
$ go version

### clone the repo
$ git clone *url of the repository*

# everything should be good to go

Testing

Concat videos with preset assets

$ go test ./pkg/render -run ConcatTest

Concat high-load stress test with preset assets

$ go test ./pkg/render -run ConcatStressTest

Create a thumbnail from a video timestamp

$ go test ./pkg/render -run ThumbnailTest

Create a video, with a specific duration, from an image

$ go test ./pkg/render -run ConvertTest

Todo List

  • Finish deployment branch
  • Add more tests (transcode, downscale)
  • Move storage to a file storage solution in the cloud (?)

Authors

josé soares

About

A somewhat simple golang REST API with the fiber framework with routes which process video and audio using the open-source software ffmpeg

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published