Skip to content

A graph processing application implemented in Rust that supports local deployment.

Notifications You must be signed in to change notification settings

jachinq/myimage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

myimage

中文

Introduction

This is an image hosting website.

Use Rust to build it.

dependencies:

  • serde + serde_json + serde_derive (for JSON serialization/deserialization)
  • tiny_http + urlencoded (for HTTP server)
  • rustsqlite + uuid + chrono (for database)
  • image + image_base64 + webp (for image processing)

Frontend: Vanlla JavaScript + HTML + CSS

Data

Index database will be created at data/data.db.

Picture files will be stored at res/pictures, every picture will have a unique UUID as its filename, and it will be generated a thumbnail when uploaded. The thumbnail is used for displaying in the frontend of list page.

Usage

Development

git clone the repository.

cargo run

This will start the server at http://localhost:8080.

deploy

cargo build --release --target x86_64-unknown-linux-musl

Then copy the binary and the web directory to the app directory.

mkdir app
cp target/x86_64-unknown-linux-musl/release/myimage app/
cp -r web app/

Start the server:

cd app
./myimage

Deploy to Docker

Prepare the Dockerfile and docker-compose.yml file.

cp Dockerfile docker-compose.yml app/

Run with docker, the project file strucure is:

app/
├── Dockerfile
├── app
│   ├── myimage
│   └── web
└── docker-compose.yml

At first, you need to use docker to build the image.

docker build -t myimage .

Run the container with docker-compose.

docker compose up -d

Update Log

  • 2026-01-18: Major optimizations have been made to the overall application interface and interaction effects, resulting in a more visually appealing waterfall-style image wall.

About

A graph processing application implemented in Rust that supports local deployment.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published