This repository has been archived on 2022-10-30. You can view files and clone it, but cannot push or open issues or pull requests.
Go to file
Odyssey346 ee6b525223 use epoch time for announcements, docker improve
Signed-off-by: Odyssey346 <odyssey346@disroot.org>
2022-08-05 15:17:56 +02:00
.github Rename to Segfautils 2022-08-02 10:42:47 +02:00
api use epoch time for announcements, docker improve 2022-08-05 15:17:56 +02:00
data use epoch time for announcements, docker improve 2022-08-05 15:17:56 +02:00
static Update announcements.html's title 2022-08-03 21:45:39 +02:00
utils initial announcements 2022-08-03 21:37:12 +02:00
docker.env add to docker.env 2022-08-04 21:20:21 +02:00
Dockerfile Rename to Segfautils 2022-08-02 10:42:47 +02:00
go.mod Switch to an actual JSON library. 2022-08-04 20:53:05 +02:00
go.sum Switch to an actual JSON library. 2022-08-04 20:53:05 +02:00
LICENSE more initial than your 2022-07-20 10:57:12 +02:00
main.go initial announcements 2022-08-03 21:37:12 +02:00
readme.md use epoch time for announcements, docker improve 2022-08-05 15:17:56 +02:00
shell.nix Rename to Segfautils 2022-08-02 10:42:47 +02:00

Segfautils

Web utilities for Project Segfault

What does it do?

For now it powers our contact form. In the future we will expand our APIs so you can do more cool things.

Setup

Docker:

docker run -d --restart=always -p 6893:6893 --name segfautils --env-file ./docker.env -v "$(pwd)"/data:/segfautils/data projectsegfault/segfautils:latest

docker.env should be the environment file located in this repository, customized to your settings. The env file is self-documenting so I don't need to go in any detail here.

We recommend using Docker as it provides better security (we suck in security, so that's why) and we are constantly updating Segfautils. Docker makes it easy to update the program.

If you're using Portainer, you should know how to add Segfautils.

git clone https://github.com/ProjectSegfault/segfautils
cd segfautils/
# You need to add the environment HCAPTCHA_SITE_KEY, HCAPTCHA_SECRET_KEY, SEGFAUTILS_WEBHOOK_URL and SEGFAUTILS_PORT.
go run main.go # Run this when you've done above, and you're planning on developing, if not, do below
go build . -o segfautils
./segfautils

NixOS

git clone https://github.com/ProjectSegfault/segfautils
cd segfautils/
nix-shell # Avoid installing Go and setting up the web port, by just running a nix shell
# You still need the environment variables HCAPTCHA_SITE_KEY, HCAPTCHA_SECRET_KEY and SEGFAUTILS_WEBHOOK_URL though!
go run main.go # If you're developing
go build . -o segfautils && ./segfautils # If you're intending to use Segfautils for production.