GithubHelp home page GithubHelp logo

ctrager / budoco Goto Github PK

View Code? Open in Web Editor NEW
40.0 5.0 21.0 1.76 MB

Budoco is an issue tracking system. It's a rewrite of BugTracker.NET, but for Dotnet Core 5. Quick and easy to get started, runs fast, but also customizable.

License: MIT License

HTML 24.13% C# 50.54% CSS 2.63% JavaScript 22.36% Shell 0.32% PLpgSQL 0.03%
bugtracker sql postgres database dotnet-core csharp issue-tracker webapp postgresql

budoco's Introduction

Budoco

Table of Contents

What is Budoco?

Budoco is a Issue (Bug/Task/Ticket) tracking system.

Budoco is built using .NET 5 ("dotnet core") and PostgreSQL.

Budoco is a rewrite of BUgtracker.NET (aka "btnet"), but this time on DOtnet COre, hence the name BU-DO-CO. Good things about Budoco which were also true of btnet:

  • Budoco is easy to install and start using.

  • It's fast and lightweight. It won't slow you down.

  • It is highly customizable if you are comfortable tweaking some SQL statements. It's not too hard because you will have some examples to follow. Here's one way that Budoco can look: https://budoco.net. You can register as a new user or sign on as "admin", password "admin". It's just demo data but please be nice.

  • It sends and receives email which gets tracked with the issue. So a good fit for a help desk, or company that works with multiple clients.

  • It has a lightweight permission system specifically for keeping external organizations separate from each other.

  • It works well with a companion screenshot app that lets you take a screenshot and post it as an issue with just two clicks.

  • If you decide to fork the code and change it, your learning curve will be short because I'm too impatient to learn fancy abstractions. Each page is pretty much get the input, read the database, throw up some HTML.

Differences from btnet:

  • Btnet allows for more customization, at least for now.
  • Btnet has a more complicated permission system. Too comlicated to use without worry.
  • Just in general, btnet tried to please everybody, whereas Budoco is just trying to please about half of you.
  • Btnet only runs on Windows. Budoco runs wherever .NET 5 runs. I've been using Linux (Ubuntu).
  • Btnet uses MS SQL Server. Budoco uses PostgreSQL.

More about btnet here; BugTracker.NET home page

I first released btnet in 2001, originally to learn the hot new language C#. Within a couple years BugTracker.NET was pretty solid. Probably thousands of organziations used it and maybe many are still using it. But, time moves on. I moved on to other technologies, and then retired and mostly stopped coding in 2016. Dev teams moved on too, to Github and Jira for their issue tracking needs. Microsoft moved on too, from Windows only .NET to cross-platform Dotnet Core. They are no longer developing the technologies btnet depends on. So, why did I decide to do a rewrite of btnet? Because it was November 2020 and I needed a distraction from the US presedential election and COVID-19, that's why.

If Budoco is amusing you in any way, let me know at [email protected]

How to Install

These instructions worked for me using Linux Mint 20 based on Ubuntu 20.04, but Budoco should run anywhere dotnet core and postgres run.

1) Install dotnet core 5 sdk

Skip to the next step if you already have dotnet core 5 sdk installed.

I used the instructions here in Nov 2020: https://docs.microsoft.com/en-us/dotnet/core/install/linux-ubuntu#2004-

wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb

sudo dpkg -i packages-microsoft-prod.deb

sudo apt-get update 

sudo apt-get install -y apt-transport-https
sudo apt-get update 
sudo apt-get install -y dotnet-sdk-5.0

Also, for the "Reports" charts feature:

sudo apt-get install libgdiplus

2) Install PostgreSQL 12

Skip to the next step if you already have postgres installed and a username/password combo ready for Budoco.

These were the steps I followed to install postgres and tweak it. I have no idea if this is best practice but it worked for me.

sudo apt install postgresql

Then use the psql command line tool to give the postgres user a password.

sudo -u postgres psql
alter user postgres password 'YOUR PASSWORD';
\q

Then change postgres configuration to require password:

sudo nano /etc/postgresql/12/main/pg_hba.conf

Change the line below so from "peer" to "md5"

local     all     postgres     peer

Restart postgres

systemctl restart postgresql

The following should now prompt for a password:

psql -U postgres

To avoid being prompted every time, create this file in your home dir:

.pgpass

with one line:

localhost:5432:*:postgres:YOUR PASSWORD

3) Create the Budoco database.

Create the database:

psql -U postgres
create database budoco;
\q

Create and load the tables. If you want to just try out Budoco, then use the demo script:

cd sql
./create_and_load_tables_demo.sh

When you are ready to use it for real, use the production script:

./create_and_load_tables_production.sh

Both scripts start by destroying whatever data is currently in the budoco database.

4) Configure Budoco

Copy the example config file. The copy must be named "budoco_config_active.txt"

cp budoco_config_example.txt budoco_config_active.txt

Open the new copy and edit it according to the instructions in it. At a minimum, change the database username and password. The hardest part for me was getting my emails to work using my gmail and yahoo accounts, because there are extra steps you have to do on their websites to allow unfamiliar apps to connect to their SMTP servers.

<RANT> Here we are in the year 2020 and Microsoft adopted a format for configuration files, "appsettings.json", that does NOT support comments. It makes me miss the ".ini" files from Windows 3.1 from the early 90s. </RANT>

Running Budoco

For testing:

dotnet run

Login as admin/admin. You will be redirected to a reset password page. If you are just playing around and want to create more users, set "DebugAutoConfirmRegistration" to 1 in budoco_config_active.txt to SKIP the step where a user would have to confirm registration by clicking on a link in an email. Change the setting back when you are running it for real.

For production I recommend that you use budoco with nginx. (Corey TODO: explain this more)

Using Budoco

The philosophy of both old BugTracker.NET and new Budoco is that they are easy to get started with but highly customizable. To get to know Buduco first try running it loaded with demo data (Corey TODO explain how to do this) and then take a tour. This should just take a few minutes:

  • Read the comments in budoco_config_example.txt to get an overview of the customizations controlled via config. Experiment with some of the customization settings.

  • Visit the "Issues" page and try the different views.

  • Visit the "Admin" page and then the Admin "Issue Queries" page and see how the SQL implements the Issue views.

  • Visit the Users and Organizations pages to get to know the permissions system.

Good luck, and let me know how it goes.

Corey Trager

budoco's People

Contributors

afract avatar ctrager avatar ivangrek 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  avatar  avatar  avatar  avatar

budoco's Issues

Fix posts N+1

SQL 1:select i_organization from issues where i_id = 4030
SQL 2:select posts.*, us_username
from posts
inner join users on us_id = p_created_by_user
where p_issue = 4030 order by p_id asc
SQL 3:select pa_id, pa_file_name, pa_file_length, pa_file_content_type
from post_attachments
where pa_post = 48 order by pa_id asc
SQL 4:select pa_id, pa_file_name, pa_file_length, pa_file_content_type
from post_attachments
where pa_post = 49 order by pa_id asc
SQL 5:select pa_id, pa_file_name, pa_file_length, pa_file_content_type
from post_attachments
where pa_post = 50 order by pa_id asc

Can not skip registration page as admin

Nice work!
I'm an old Visual Studio user and not very handy with VS Code and .NET Core stuff.
I tried the following on Windows 10 using the Edge browser, but can not get past the login page.
As you already mentioned using Gmail is not that easy either, maybe it's possible to show a simple "SKIP" button in DEBUG mode?

set "DebugAutoConfirmRegistration" to 1 in budoco_config_active.txt to SKIP the step where a user would have to confirm registration

Cache dropdown contents until admin makes them dirty (custom, org, for example)

This is pulling up the issue create form

SQL 1:/check_user_permissions/ select * from sessions
inner join users on se_user = us_id
where se_id = '46db6f69-dad5-49de-b9d3-c4e15d4724f4'; /*check_user_permissions */
SQL 2:select og_id, og_name from organizations where og_is_active = true union select 0, '[None]' order by og_name
SQL 3:select us_id, us_username from users where us_is_active = true order by us_username
SQL 4:select c1_id, c1_name from custom_1 where c1_is_active = true order by c1_name
SQL 5:select c2_id, c2_name from custom_2 where c2_is_active = true order by c2_name
SQL 6:select c4_id, c4_name from custom_4 where c4_is_active = true order by c4_name
SQL 7:select og_id, og_name from organizations where og_is_default is true order by og_name limit 1
SQL 8:select c1_id from custom_1 where c1_is_default is true order by c1_name limit 1
SQL 9:select c2_id from custom_2 where c2_is_default is true order by c2_name limit 1
SQL 10:select c4_id from custom_4 where c4_is_default is true order by c4_name limit 1
layout_si

Incoming email post, "Reply".

Only appears according to permission, so not for is_report_only users.
Clicking Reply for incoming email post would take you to the post form, preselected for email, prepoulated with the email address, and prepulated with quoted text.

[Feature request] Migration from BugTracker.Net to Budoco ?

Hello Corey,

I am using a slightly customized version of BugTracker.Net since many years for private purpose.
I was wondering if you plan (or already did) a tool to migrate all posts / users / projects from an existing btnet database to a fresh installation of Budoco ?
I would like to give a try budoco (unless if you say it's not a good idea because it's not maintained and it may have some flaws or major features missing ?) but I don't want to lose my existing btnet data.

Thanks a lot for BugTracker.Net ! Despite its code is a bit old, it works really well and it was easy for me to modify it to add my own requirements. Initially if I installed budoco it was because it was the only bugtracker I've found that was compatible with my old Windows Server 2003 I was using at the time, so you can guess since how much time I'm using it ;)

Richard

column "rp_desc" does not exist

Fresh install, dotnet run fails witht he following error:

at budoco.Program.Main(String[] args) in /home/plompt/budoco-master/Program.cs:line 56
Exception data:
Severity: ERROR
SqlState: 42703
MessageText: column "rp_desc" does not exist
File: tablecmds.c
Line: 3138
Routine: renameatt_internal

Fixed by running the following SQL:

BEGIN; update db_version set db_version = 4; COMMIT;

Electron screenshot tool that can post to Budoco, like the old BugTracker.NET tool

@ivangrek - Does this interest you?

So far I can see that electron can take a screenshot of the entire desktop, but not off a selection. So, I'm thinking a way to do it would be to create like a transparent window for doing the selection, then take the screenshot of the whole desktop, then apply the selection rectangle to whole desktop image.

So, step number one, can I produce an electron window that simulates rubber band selection?

when urls appear in description, details, or post text, turn them into clickable <a> tags.

This needs to happen on the client side, because we don't want to use dangerous @Html.Raw on server. See how Search.cshtml turns the postgresql start/end markers into and tags and follow that pattern.

For recognizing urls, but maybe we also want to recognize example.com, example.org, and even example.net, even though that works bad with my own "BugTracker.NET".

url parser
https://mathiasbynens.be/demo/url-regex
https://gist.github.com/dperini/729294
Copyright (c) 2010-2018 Diego Perini (http://www.iport.it)

I don't know how to allow a post from a "foreign" source (for posting screenshots from separate app)

020-12-12 17:25:29.676 -06:00 [INF] 4 Startup.cs URL: http://localhost:5000/CreateIssue
2020-12-12 17:25:29.683 -06:00 [INF] Executing endpoint '/CreateIssue'
2020-12-12 17:25:29.700 -06:00 [DBG] Registered model binder providers, in the following order: ["Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BinderTypeModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ServicesModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BodyModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.HeaderModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FloatingPointTypeModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.EnumTypeModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DateTimeModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.SimpleTypeModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CancellationTokenModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ByteArrayModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormFileModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormCollectionModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.KeyValuePairModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DictionaryModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ArrayModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CollectionModelBinderProvider","Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ComplexObjectModelBinderProvider"]
2020-12-12 17:25:29.742 -06:00 [INF] Route matched with {page = "/CreateIssue"}. Executing page /CreateIssue
2020-12-12 17:25:29.743 -06:00 [DBG] Execution plan of authorization filters (in the following order): ["Microsoft.AspNetCore.Mvc.ViewFeatures.Filters.AutoValidateAntiforgeryTokenAuthorizationFilter"]
2020-12-12 17:25:29.744 -06:00 [DBG] Execution plan of resource filters (in the following order): ["Microsoft.AspNetCore.Mvc.ViewFeatures.Filters.SaveTempDataFilter"]
2020-12-12 17:25:29.744 -06:00 [DBG] Execution plan of action filters (in the following order): ["Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter (Order: -3000)"]
2020-12-12 17:25:29.745 -06:00 [DBG] Execution plan of exception filters (in the following order): ["None"]
2020-12-12 17:25:29.746 -06:00 [DBG] Execution plan of result filters (in the following order): ["Microsoft.AspNetCore.Mvc.ViewFeatures.Filters.SaveTempDataFilter"]
2020-12-12 17:25:29.754 -06:00 [DBG] Connection id "0HM4UUKRB9TAU", Request id "0HM4UUKRB9TAU:00000002": started reading request body.
2020-12-12 17:25:29.755 -06:00 [DBG] Connection id "0HM4UUKRB9TAU", Request id "0HM4UUKRB9TAU:00000002": done reading request body.
2020-12-12 17:25:29.760 -06:00 [INF] Antiforgery token validation failed. The required antiforgery cookie ".AspNetCore.Antiforgery.uO77BpFhTRE" is not present.
Microsoft.AspNetCore.Antiforgery.AntiforgeryValidationException: The required antiforgery cookie ".AspNetCore.Antiforgery.uO77BpFhTRE" is not present.
at Microsoft.AspNetCore.Antiforgery.DefaultAntiforgery.ValidateRequestAsync(HttpContext httpContext)
at Microsoft.AspNetCore.Mvc.ViewFeatures.Filters.ValidateAntiforgeryTokenAuthorizationFilter.OnAuthorizationAsync(AuthorizationFilterContext context)
2020-12-12 17:25:29.778 -06:00 [INF] Authorization failed for the request at filter 'Microsoft.AspNetCore.Mvc.ViewFeatures.Filters.AutoValidateAntiforgeryTokenAuthorizationFilter'.
2020-12-12 17:25:29.785 -06:00 [INF] Executing HttpStatusCodeResult, setting HTTP status code 400
202

Notifications via email aka subscribe/unsubscribe, aka watch/unwatch

The UI:

global enable in budoco_settings_active.txt for notifications

(global enable whether to send notifications to email addresses that are not users (from incoming emails) - but then we'd need a way for external users to unsubscribe, so.... no, don't do this)

at user, radio buttons
subscribe to all
subscribe only to issues created/updated by me <<== default
subscribe to none

new user_issue table for explicit sub/unsub

The Backend:

We want to handle where user updates an issue, then quickly updates it again, and again. We want to send only one notification. So when we queue up the notifications, don't do multiple, and make sure they are stale by a configurable amount of minutes in settings file.

For now, email doesn't have to say what was updated.

Don't send an email to the person who did the update.

Reports - some revisions

Charts look better against white background rather than black because of the way, for example, pie charts reach the edge of the image.

Use budoco.css class=, not local style=

The ability to view - but not CRUD - reports should be made available to non-admins, but the report queries need to be filtered by org just like view queries, using the common bd_util function. So "Reports" on the menu bar for everybody, and then the Admin page would have a link to "Create/Update Reports".

The crud of reports should be more consistent with the crud of queries, for example, delete confirmation. But maybe the report way is nicer? Just they should be the same, but I'm leaning towards it being the reports that has to change, not the rest of the app.

Revisit the sizes and fonts used in the graph images and maybe make them configurable? I dunno.

Make the ability to control the issue page's layout with css easier

Underneath the "Details" textarea are up to 8 dropdowns: org, assigned to, and the 6 custom fields. Right now they are laid out using actual

tags, in two columns.

What I would like is that the layout is completely controlled by css and that the user can override whatever we do in css using the custom css file feature of the app.

For the initial experience, new installation, I would like two columns
Left:
org
priority aka custom 2
[custom 3] hidden
category aka custom 4
[custom 5] hidden

right
assigned to
status aka custom 1

but I would like custom css to demo how to move things around between columns.

IIS hosting is not working in windows 10

Hi all,

I deployed this application (budoco .NET 5 ) in the IIS and Microsoft Azure. But both are not working. Could you please help on this.

From IIS:

image

From Azure:
image

Thanks & Regards,
Thiru

Users page - views, sorting, like issue page,

For when the number of users gets big, something like the issues page - more control over list
checkbox to include/exclude inactive users
dropdown for all organizations or specific organization
A little searchbox to search usernames and email
Sort by clicking on column headings

Also: add OPTIONAL first name, last name to users table, user settings, etc

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.