GithubHelp home page GithubHelp logo

jgeusebroek / docker-privatebin Goto Github PK

View Code? Open in Web Editor NEW
20.0 3.0 10.0 22 KB

A tiny Docker image running Alpine Linux and Privatebin.

Home Page: https://github.com/PrivateBin/PrivateBin

License: MIT License

Shell 23.30% Dockerfile 76.70%

docker-privatebin's Introduction

Docker Privatebin image

A tiny image running alpine Linux and PrivateBin.

Usage

docker run --restart=always -d \
	--read-only \
	-p 0.0.0.0:80:80 \
	--hostname=privatebin \
	--name=privatebin \
	-v /<host_data_directory>:/privatebin/data \
	-v /<host_cfg_directory>:/privatebin/cfg \
	jgeusebroek/privatebin

On first run it will copy the sample config file, if there isn't a config file already.

Optional environment variables

  • UID User ID php fpm daemon account (default: 991).
  • GID Group ID php fpm daemon account (default: 991).

License

MIT / BSD

Author Information

Jeroen Geusebroek

docker-privatebin's People

Contributors

andreipoe avatar djmattyg007 avatar djmaze avatar elrido avatar jgeusebroek avatar

Stargazers

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

Watchers

 avatar  avatar  avatar

docker-privatebin's Issues

MySQL support

Any chance you can incorporate MySQL support?

#2 /privatebin/index.php(18): PrivateBin\PrivateBin->__construct()
#3 {main}
  thrown in /privatebin/lib/Configuration.php on line 168" while reading response header from upstream, client: 10.0.0.90, server: , request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm.sock:", host: "paste.xxxxxxx.xxxx"
2018/03/18 21:56:40 [error] 19#19: *9 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Class 'PDO' not found in /privatebin/lib/Configuration.php:168
Stack trace:
#0 /privatebin/lib/PrivateBin.php(182): PrivateBin\Configuration->__construct()
#1 /privatebin/lib/PrivateBin.php(131): PrivateBin\PrivateBin->_init()
#2 /privatebin/index.php(18): PrivateBin\PrivateBin->__construct()

Crash on start-up when using a read-only file system

If running the container with --read-only, it crashes on start-up:

chown: /var/tmp/nginx: No such file or directory
2020-01-16 05:19:47,535 INFO Set uid to user 0 succeeded
2020-01-16 05:19:47,543 INFO supervisord started with pid 10
2020-01-16 05:19:48,548 INFO spawned: 'nginx' with pid 12
2020-01-16 05:19:48,558 INFO spawned: 'php-fpm' with pid 13
nginx: [emerg] mkdir() "/var/lib/nginx/tmp/client_body" failed (30: Read-only file system)
2020-01-16 05:19:48,605 INFO exited: nginx (exit status 1; not expected)
2020-01-16 05:19:49,613 INFO spawned: 'nginx' with pid 16
2020-01-16 05:19:49,614 INFO success: php-fpm entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
nginx: [emerg] mkdir() "/var/lib/nginx/tmp/client_body" failed (30: Read-only file system)
2020-01-16 05:19:50,639 INFO success: nginx entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2020-01-16 05:19:50,640 INFO exited: nginx (exit status 1; not expected)

Removing the flag from docker run allows it to run normally. Tested with PrivateBin 1.3.1 and 1.3.2.

PrivateBin 1.3.5

Hello !

Is it possible to have the 1.3.5 update ? We're running 1.3.4 with the "latest" tag

Thank you so much ^^

Unable to share attachments or large pastes

When attempting to share large pastes or files, an error occurs in nginx. Its unable to create a file in the /var/lib/nginx/tmp/client_body/ The error might be related to permissions:

  1. https://wincent.com/wiki/Fixing_nginx_client_body_temp_permission_denied_errors

Here is a sample of the log output using docker logs:

2020/10/07 17:18:33 [crit] 14#14: *1 open() "/var/lib/nginx/tmp/client_body/0000000001" failed (13: Permission denied), client: 1.1.1.5, server: , request: "POST / HTTP/1.1", host: "privatebin.XXX.org"

I have spent a few hours trying to get it to work, but not been successful.

ARM builds?

Is it possible for you to build the image for ARM64 too?

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.