Code Monkey home page Code Monkey logo

roim-picx's Introduction

roim-picx

预览地址

roim-picx

该系统仅作为预览使用,每天有使用限额,请勿大量上传图片。不要使用该图床的地址作为生产使用,因为要定时删除。

一款基于Cloudflare的Worker、R2、Pages实现的图床应用,具有以下特点:

  • 10GB的免费存储空间
  • 每月300W次的不计流量的图片访问,每天10W的限制。
  • 每月100W次的图片上传次数
  • 不需要自己购买服务器,克隆代码后部署CloudFlare即可使用。
  • 独立部署不需要担心被第三方删除数据。

Token

4xVSYkCKw2ExbPNEaMPjCnaaOowU9sTf

已实现功能

  • 图片批量上传
  • 图片列表查询
  • 图片删除
  • 目录创建
  • 按目录查询
  • 链接地址点击复制
  • 简单的身份认证功能,进入管理页面需要授权

TODO

  • 上传时支持选择目录。
  • 提供删除图片的访问链接
  • 管理页面支持分页加载图片

使用教程

  • 1.fork项目到自己的github
  • 2.注册CloudFlare并开通R2服务 Upload
  • 3.找到Pages选项并且创建项目 Upload
  • 4.选择项目创建方式 Upload
  • 4.链接Github或GitLab并选需要构建的项目 Upload Upload
  • 5.设置环境变量

因为cloudflare默认的node版本较低需要手动指定版本,否在会导致构建失败. Upload

  • 6.设置项目的函数信息绑定R2和KV服务 Upload Upload
  • 7.构建项目,提示成功即可访问 Upload

注意:Pages的函数变量名称需要于项目的变量名称一致,如果需要修改functions里面的Env名空间,对应的文件是[[path]].ts

图床截图

Upload Preview HTML Markdown Link Manage

项目参考来源

1. cfworker-kv-image-hosting

2. HikariSearch

roim-picx's People

Contributors

chinazyq123 avatar roimdev 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

Watchers

 avatar

roim-picx's Issues

上传的文件保持原来的文件名

我看到上传的文件都是通过 randomString 进行重新命名了,请问如果想要保持原来最原始的文件名,有什么方法吗?谢谢。

Error: No known conditions for "./lib/locale/lang/zh-cn" entry in "element-plus" package

在 cloudflare pages 部署提示 error 了:

16:39:05.294    [commonjs--resolver] No known conditions for "./lib/locale/lang/zh-cn" entry in "element-plus" package
16:39:05.295    error during build:
16:39:05.295    Error: No known conditions for "./lib/locale/lang/zh-cn" entry in "element-plus" package
16:39:05.295        at bail (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:32678:8)
16:39:05.296        at resolve (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:32750:9)
16:39:05.296        at resolveExports (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:34135:12)
16:39:05.296        at resolveDeepImport (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:34153:31)
16:39:05.296        at tryNodeResolve (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:33842:20)
16:39:05.297        at Object.resolveId (file:///opt/buildhome/repo/node_modules/vite/dist/node/chunks/dep-372dab03.js:33602:28)
16:39:05.297        at file:///opt/buildhome/repo/node_modules/rollup/dist/es/shared/rollup.js:22748:40
16:39:05.297        at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
16:39:05.312    Failed: Error while executing user command. Exited with error code: 1
16:39:05.323    Failed: build command exited with code: 1
16:39:06.150    Failed: error occurred while running build command

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.