web based homebrew repo manager

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
I found https://github.com/vgmoose/barkeep as a way to create an local homebrew repository, however, it looks like the last update was 4 years ago. Knowing this, i tried to use the xenial docker image (since the Dockerfile is just specifying ubuntu) however because it is using pip, some of the packages do not want to compile/install. Is there any newer web-based repo creator? (i've been spoiled by nsp-indexer for a custom/local tinfoil shop) -- if not, i might be able to write something that is ugly but would work, i just don't want to duplicate work if possible.

thanks!
 

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
I found https://github.com/vgmoose/barkeep as a way to create an local homebrew repository, however, it looks like the last update was 4 years ago. Knowing this, i tried to use the xenial docker image (since the Dockerfile is just specifying ubuntu) however because it is using pip, some of the packages do not want to compile/install. Is there any newer web-based repo creator? (i've been spoiled by nsp-indexer for a custom/local tinfoil shop) -- if not, i might be able to write something that is ugly but would work, i just don't want to duplicate work if possible.

thanks!
I’m interested in this as well! Very cool!

Considering the date I think you might want to use an Ubuntu tag circa the same era.

Python has changed quite a bit in 5 years…just sayin.

Maybe one of these would do it?

https://hub.docker.com/_/ubuntu/tags?page=10

e: I just spun up a new Pi Ubuntu image and am going with Bionic. I think we’re’ going to have to pin the Python requirements as well because I’m getting syntax errors during build. There are no constraints so it’s probably pulling down latest and greatest which will likely not be 2019 syntax compatible…

flask
flask-sqlalchemy
mysql-python
flask-login
flask-migrate
flask-wtf
flask-bootstrap

Based on the last commit dates I’m going to change my target to whatever was in circulation as of 14 May 2018 and see if we can get something to light up…

4920D3E9-EB08-48AC-8847-8CB5173622EB.jpeg
 
Last edited by binkinator,
  • Like
Reactions: peteruk

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
I’m interested in this as well! Very cool!

Considering the date I think you might want to use an Ubuntu tag circa the same era.

Python has changed quite a bit in 5 years…just sayin.

Maybe one of these would do it?

https://hub.docker.com/_/ubuntu/tags?page=10
Yeah -- that is why i tried xenial -- but i must have read the table wrong -- bionic was 2018, xenial was 2016.

i was able to get it to build, but now i'm getting tons of python errors. I'll let you know when i get it figured out
Post automatically merged:

sorry for the quick follow up (it's been awhile, so i forgot you could pin with pip)

here is my requirements file that allowed me to get the app started:

flask <=1.0.3
flask-sqlalchemy <=2.3.2
mysql-python <=1.2.5
flask-login <=0.4.1
flask-migrate <=2.1.1
flask-wtf <0.14.2
flask-bootstrap <=4.0.2
werkzeug==0.16.1


there are a couple newer versions of the packages that i will play with, but once i have everything working, i'll make a fork on github and do a pull request, and if not, at least my fork will work
 
Last edited by izenn,

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
Yeah -- that is why i tried xenial -- but i must have read the table wrong -- bionic was 2018, xenial was 2016.

i was able to get it to build, but now i'm getting tons of python errors. I'll let you know when i get it figured out
Post automatically merged:

sorry for the quick follow up (it's been awhile, so i forgot you could pin with pip)

here is my requirements file that allowed me to get the app started:

flask <=1.0.3
flask-sqlalchemy <=2.3.2
mysql-python <=1.2.5
flask-login <=0.4.1
flask-migrate <=2.1.1
flask-wtf <0.14.2
flask-bootstrap <=4.0.2
werkzeug==0.16.1


there are a couple newer versions of the packages that i will play with, but once i have everything working, i'll make a fork on github and do a pull request, and if not, at least my fork will work

Using a base of

Code:
from ubuntu:xenial-20180417

I have a 100% clean build with the following requirements.txt:

Code:
visitor==0.1.3
WTForms==2.1
dominate==2.3.1
six==1.11.0
MarkupSafe==1.0
Mako==1.0.7
alembic==0.9.9
SQLAlchemy==1.2.7
itsdangerous==0.24
Jinja2==2.10
Werkzeug==0.14.1
click==6.7
flask==1.0.2
flask-sqlalchemy==2.3.2
mysql-python==1.2.5
flask-login==0.4.1
flask-migrate==2.1.1
flask-wtf==0.14.2
flask-bootstrap==3.3.7.1

E: Having to build my own MySQL container because I’m doing this on a Raspberry Pi. Ungh
Post automatically merged:

I'm up and running!

I was able to create a user via the GUI in the backend DB.

...not entirely sure how to set up and populate get repos (not git repos...get repos.)

https://github.com/fortheusers/libget

Anyway...here it is!

1670555966279.png

Post automatically merged:

Raging clue?

https://github.com/fortheusers/hb-appstore#maintaining-a-repo

https://github.com/fortheusers/libget#setting-up-repos
 
Last edited by binkinator,
  • Like
Reactions: vgmoose and peteruk

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
I forked and modded as well, just the stuff needed to get it to work on Arm architecture. Feel free to copy pasta anything. Looking forward to any tweaks you might add. I’m going to try and track down more info on how to use get repots on their Discord.
Post automatically merged:

Check this out…

https://github.com/pwsincd/appstore/
Post automatically merged:

This tool feels like it is the backend for the backend of the frontend for HB AppStore. Part of an ecosystem if you will.

I was hoping this would be a “build your own App Store” type of thing where I could store my collection of apps at the version I wanted and quickly reinstall everything in the event I needed to redeploy my switch from scratch.

@adambot what are you going to ultimately use this for?
 
Last edited by binkinator,
  • Like
Reactions: peteruk

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
my goal is to host my own personal stores so i don't need to connect to the internet ever. (i have my wifi set to allow my switch to only allow local access and block all outgoing and incoming traffic from the internet.)

an i know i could use ftp or take out the sd card, but i like the idea of my own store better for some reason -- like i said, spoiled by nspindexer (which i'm also working on a fork of right now. i have it mostly good, just want to add a delete button for updates.
 
  • Like
Reactions: binkinator

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
my goal is to host my own personal stores so i don't need to connect to the internet ever. (i have my wifi set to allow my switch to only allow local access and block all outgoing and incoming traffic from the internet.)

an i know i could use ftp or take out the sd card, but i like the idea of my own store better for some reason -- like i said, spoiled by nspindexer (which i'm also working on a fork of right now. i have it mostly good, just want to add a delete button for updates.
Yeah…totally get it. I love the convenience of ftp and the speed of MTP but a self hosted store would be awesome! I like having options.
 
  • Like
Reactions: peteruk

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
so it looks like the pwsincd appstore is based off an old/buggy version of the code found here https://github.com/fortheusers/libget/tree/master/web

i was able to get a package created, zipped, and the repo.json generated. i'm going to tweak it a bit more and then i'll start writing a basic web front end. it'll be simple, but i figure if it is out there maybe someone else can help make it nicer.
 

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
so it looks like the pwsincd appstore is based off an old/buggy version of the code found here https://github.com/fortheusers/libget/tree/master/web

i was able to get a package created, zipped, and the repo.json generated. i'm going to tweak it a bit more and then i'll start writing a basic web front end. it'll be simple, but i figure if it is out there maybe someone else can help make it nicer.

Looks like there’s more activity over here:

https://gitlab.com/4TU/
 

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
Looks like there’s more activity over here:

https://gitlab.com/4TU/
looks like https://gitlab.com/4TU/spinarak replaced the repogen i had been using -- i'll have to look into that, shouldn't be hard to move to that.

edit:
i'll finish what i have and then see if i can update to the new package -- looks like they changed things a bit more than i initially thought. (grumble grumble. json grumble)
Post automatically merged:

Looks like there’s more activity over here:

https://gitlab.com/4TU/

my initial code was not bad, but they are so much more advanced on the new gitlab stuff.

i'm almost done adapting all their code for localhost use -- just trying to figure out the best way to upload a zipped package now -- i was hoping to do it all in one shot, but i'm not sure if i'll be able to do that. i think what i am going to do first is make it work with 2 submits, 1 for zip info and banner/poster images, (which is what is making me scratch my head -- picture uploads to json and zip to filesystem is what i need, but that is slightly tricky for me right now -- maybe i'll have an idea after some sleep). after i'm comfortable with how everything is working, then i'll go back to figure out how to combine everything into a single upload.

i'm hoping to have a prototype done tomorrow, then i'll make a docker-create.yml and put that on github so people can kick the tires a bit

once this project is done, i'll go back and finish my updates to nsp-indexer -- just docker config left and then maybe a new (delete) button for updates, but that's a way down the road
 
Last edited by izenn,
  • Like
Reactions: binkinator

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
Initial commit of the docker container for a working local homebrew repo and frontend has been committed. please kick the tires and let me know if you find anything wonky or if anything needs to be explained better

https://gitlab.com/izenn/hbas-local
Wow…such a a clean build process. 😁

6BF6F7F0-2DF5-4F79-B6FF-FC223DC381D4.jpeg


E: After an app submission it seems there’s something hard coded for

http://192.168.1.100:5000/status.html

WhenI correct it for my internal server on 192.168.4.30 it displays the following:

670248E5-2017-4211-B6B1-80778FB7F100.jpeg

So very very close!1111!

E2: I think I found it here. Going to try some things…

CB091C10-90C3-4E4C-B23D-F3340EB23A0A.jpeg
 
  • Like
Reactions: peteruk

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
Wow…such a a clean build process. 😁

View attachment 342785


E: After an app submission it seems there’s something hard coded for

http://192.168.1.100:5000/status.html

WhenI correct it for my internal server on 192.168.4.30 it displays the following:

View attachment 342784

So very very close!1111!

E2: I think I found it here. Going to try some things…

View attachment 342787
ahh! i missed the LibGet.js -- i'll get that fixed -- the docker-compose and repos files need to be modified -- i'll make sure to note that in the documentation
 

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
ahh! i missed the LibGet.js -- i'll get that fixed -- the docker-compose and repos files need to be modified -- i'll make sure to note that in the documentation

I modified it by hand and was able to move forward. It;s complaining that my directories aren’t empty. Need to figure out what it’s trying to overwrite.
 
  • Like
Reactions: peteruk

izenn

Active Member
OP
Newcomer
Joined
Jun 14, 2011
Messages
37
Trophies
1
XP
183
Country
United States
I modified it by hand and was able to move forward. It;s complaining that my directories aren’t empty. Need to figure out what it’s trying to overwrite.
yup -- already fixed the missing directory issue - running a test now, but at this point most issues should be cleaned up -- it will complain about node and spinarak directories not being empty. i'm working on figuring out a clean way to update those -- shouldn't be too hard with git, just need to find the right command
Post automatically merged:

OK -- i figured out the git stuff and was able to stop it from complaining and it will actually update the repos properly now. (i was cheating before and just doing a git clone rather than a git pull). commits have been made to my gitlab repo.
Post automatically merged:

WhenI correct it for my internal server on 192.168.4.30 it displays the following:

View attachment 342784
also -- for the error you are getting on the status page -- you need sd at the root of the directory tree in your zip (i had a feeling people were going to hit that issue, so i put it in the helpful tips section of the readme when i did the initial commit -- the reason is sometimes apps install outside of the switch directory, so i needed a clean way to handle that -- using the appstore package as an example, that is what they did there, and it made sense
Post automatically merged:

ok -- thought about it more -- it is stupid to require /sd at the beginning. i just removed that and am testing now
 
Last edited by izenn,
  • Love
Reactions: binkinator

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,511
Trophies
2
XP
6,152
Country
United States
There was some kind of issue with upstream installation of python and node timing out last night. Woke up this morning and tried it from a clean clone of your repot and…

It worked perfectly!

D4E7A3E9-1023-4F7D-9C4A-5F5A2E12D699.jpeg

7A932C84-9AC3-4C43-88AC-5989D52F1B28.jpeg

7908B4E3-DCBF-4258-A2CF-E14B6B10085B.jpeg

358F7762-9110-4727-B348-9A40DED16710.jpeg

DD4A6CFB-9084-4B1D-9C25-53E0D82B5FA6.png


This was just a quick example, but hot damn this is a huge leap you’ve made and it’s working!
 
Last edited by binkinator,

vgmoose

Well-Known Member
Member
Joined
Jan 31, 2016
Messages
360
Trophies
1
Website
github.com
XP
3,045
Country
United States
Using a base of

Code:
from ubuntu:xenial-20180417

I have a 100% clean build with the following requirements.txt:

Code:
visitor==0.1.3
WTForms==2.1
dominate==2.3.1
six==1.11.0
MarkupSafe==1.0
Mako==1.0.7
alembic==0.9.9
SQLAlchemy==1.2.7
itsdangerous==0.24
Jinja2==2.10
Werkzeug==0.14.1
click==6.7
flask==1.0.2
flask-sqlalchemy==2.3.2
mysql-python==1.2.5
flask-login==0.4.1
flask-migrate==2.1.1
flask-wtf==0.14.2
flask-bootstrap==3.3.7.1

E: Having to build my own MySQL container because I’m doing this on a Raspberry Pi. Ungh
Post automatically merged:

I'm up and running!

I was able to create a user via the GUI in the backend DB.

...not entirely sure how to set up and populate get repos (not git repos...get repos.)

https://github.com/fortheusers/libget

Anyway...here it is!

View attachment 342135
Post automatically merged:

Raging clue?

https://github.com/fortheusers/hb-appstore#maintaining-a-repo

https://github.com/fortheusers/libget#setting-up-repos


Thanks for fixing the dependencies in the barkeep codebase! Kind of funny that at the time I thought adding docker would future-proof it, yet the versions for both the requirements.txt and the docker image weren't pinned.

As noticed here, we went through a few different ways to organize the backend over time, and barkeep ultimately never really got used. It's main goal was going to be to just help edit package json data. Using spinarak though with the pkgbuilds via CI is the "latest" way to do it.

Initial commit of the docker container for a working local homebrew repo and frontend has been committed. please kick the tires and let me know if you find anything wonky or if anything needs to be explained better

https://gitlab.com/izenn/hbas-local

Thank you for putting this together for the locally hosted use-case, and making it easier to work with! I too hate grabbing other devices/FTP/SD cards/etc, and the more done directly on the console the better/easier.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    LeoTCK @ LeoTCK: im going off now...I'll turn off my brain