Code Monkey home page Code Monkey logo

captcha's People

Contributors

albilaga avatar aldy505 avatar artileda avatar dependabot[bot] avatar elianiva avatar kokizzu avatar raywp avatar ronnygunawan avatar wahidinaji avatar yogipristiawan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

captcha's Issues

bot functionality

lets make this as just a captcha bot with a few functions that are also available on the C# and JS version.

Implement better config file reading & verification

Rather than just leaving the godotenv to read the .env file, we should verify it.

On the main.go file, we could put an init() function and that would call a function to verify the config. If there's a missing config, the app would throw an error.

Feature flag system for custom features

Since we're in the path for deprecating captcha-lite, and making it possible for others to self host their own captcha bot, we need to disable some stuff and make everything configurable using feature flag system.

  • Analytics (requires Postgres instance)
  • Badwords (requires Mongo instance)
  • Captcha (must be enabled by default)
  • Dukun (requires Mongo instance)
  • Underattack (requires Postgres instance -- must be possible to use other persistence method)

Handle better graceful shutdown

Implement this:

	log.Println("Bot started!")
	go func() {
		bot.Start()
	}()

	signalChan := make(chan os.Signal, 1)
	signal.Notify(signalChan, syscall.SIGINT, syscall.SIGTERM)
	<-signalChan
	log.Println("Shutdown signal received, exiting...")

cc @artileda

Documentation for running the captcha bot as a Docker container

Here is described that the bot can be deployed through Docker:

https://github.com/teknologi-umum/captcha-lite/blob/f4fa0a4b0d6c179a28de1f518373e3e48589a33d/README.md?plain=1#L22-L27

Yet, the reality of deploying with Docker is not that simple, we have to put the correct environment variables, preferably providing a limiter for RAM and CPU consumption. Some users that are using Docker as their main driving deployment pipeline might need that.

We also have our own container package that can be accessed here: https://github.com/orgs/teknologi-umum/packages?repo_name=captcha-lite - It might be useful to just pull the image from that registry, rather than building the image from cloning the source code.

Deploying on a format of Docker Compose might also be useful.

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.