Giter Site home page Giter Site logo

xpnas / yopngs Goto Github PK

View Code? Open in Web Editor NEW
168.0 2.0 54.0 115 KB

纯粹图床,支持鉴黄,支持压缩,支持本地存储,COS存储,OSS存储,B2存储

Home Page: https://www.yopngs.com

License: MIT License

C# 60.04% Dockerfile 0.93% HTML 4.52% JavaScript 25.56% CSS 8.96%

yopngs's Introduction

yopngs

示例站点:有图床

Docker Image master

一个纯粹的开源图床,聚焦图床核心功能,抛去用户验证、上传限制,自带鉴黄功能

支持鉴黄、支持压缩、支持本地存储、COS存储、OSS存储、B2存储

使用方法

发布版

请先确认已安装DockerCompose

wget "https://raw.githubusercontent.com/xpnas/yopngs/master/docker-compose.yml" 
docker-compose up -d

配置Nginx代理

server
{
 location / {
 proxy_pass http://localhost:8081;
 proxy_http_version 1.1;
 proxy_set_header Upgrade $http_upgrade;
 proxy_set_header Connection keep-alive;
 proxy_set_header Host $host;
 proxy_cache_bypass $http_upgrade;
  }
}

配置存储源

所有配置都在config目录下的setting.json文件,可参照defaultsetting.json修改

本地存储

DISKStores节点,支持多个,可使用docker启动命令映射Rclone挂载的磁盘

  "DISKStores": [
    {
      "diskfloder": "/yopngs",//本地目录,docker请做映射
      "webfloder": "/v1",//url目录,如https://yopngs.com/v1/2022/01/01/xxxxx.png
      "name": "yopngs",//主界面下拉显示名称,随意填写
      "type": "yopngs",//内部类型,随意填写
      "index": 0,//主界面下拉排序,越小越优先
      "active": true//是否激活
    },

Backblaze2存储

B2Stores节点,支持多个

"B2Stores": [
  {
    "KeyId": "xx",
    "ApplicationKey": "xx",
    "BucketId": "xx",
    "Domain": "https://xx.com",//建议在B2前套上Cloudflare,使用自定义域名
    "Safe":false,//建议使用Cloudflare规则以避免暴露B2信息,防止有心人刷B2流量,开启后将去除Url中的file/BucketName
    "name": "backblazeb2",
    "type": "backblazeb2",
    "index": "2",
    "active": true
   }

腾讯COS存储

COSStores节点,支持多个

  "COSStores": [
    {
      "region": "ap-shanghai",
      "bucket": "xx",
      "SECRET_ID": "xx",
      "SECRET_KEY": "xx",
      "Domain": "https://xx.com",
      "name": "COS",
      "type": "COS",
      "index": 1,
      "active": false
    }
  ],

阿里OSS存储

OSSStores节点,支持多个

  "OSSStores": [
    {
      "AccessKeyId": "xxx",
      "AccessKeySecret": "xx",
      "Endpoint": "xx",
      "Domain": "https://xx.com",
      "name": "OSS",
      "type": "OSS",
      "index": "2",
      "active": false
    }
  ],

其他设置

  "GLOBAL": {
    "SIZELIMIT": 30,//图片大小
    "EXTLIMIT": ".PNG.GIF.JPG.JPEG.BMP",//类型限制
    "NSFW": true,//鉴黄开关
    "NSFWCORE": 0.5,//鉴黄分数0~1
    "NSFWHOST": "http://nsfwapi:5000",//请勿修改
    "SERVERHOST": "http://yopngs:80",//请勿修改
    "COMPRESS": false,//是否启用压缩
    "COUNT": 0,
    "STARTDATE": "2020.01.01"
  },

yopngs's People

Contributors

xpnas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

yopngs's Issues

关于Typora对接yopngs

请教一下, 可以使用 Typora 粘贴图片的时候直接对接 yopngs 的API上传到指定的图床环境吗?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.