Submit

Back to the channels

#primate

  1. * phaleth joined #primate
  2. * phaleth joined #primate
  3. phaleth winamp works well on this linux https://images4.imagebam.com/4b/e0/01/ME1DN6UL_o.png
  4. blue hi phaleth
  5. blue LOL
  6. blue TIL: you can nest classes in CSS
  7. blue I've been so out of css dev that the world has progressed and I totally missed it
  8. blue so instead of writing `.header .title {}`, you can write `.header { display: flex; \n.title { font-size: 22px } }`
  9. blue so for repopack.com, we'll need two containers and a volume: the js runtime container, a postgres db, and storage for repos
  10. * phaleth joined #primate
  11. blue wb
  12. phaleth hi blue
  13. phaleth but is css nesting well supported in all browsers?
  14. blue yes phaleth
  15. blue https://caniuse.com/?search=css+nesting
  16. nevet "css nesting" | Can I use... Support tables for HTML5, CSS3, etc
  17. blue unless you're on ie 11 :P
  18. blue it's amazing what modern css can do. it's almost like you don't need all this garbage tailwind nonsense
  19. blue dreamreal: https://www.youtube.com/watch?v=uF8YUB4kRBw
  20. nevet YouTube: Iron Maiden - Seventh Son Of A Seventh Son | Bruno Terrosa
  21. skillbot 04,01► 14,01YouTube :: Iron Maiden - Seventh Son Of A Seventh Son
  22. phaleth that's nice
  23. blue yes
  24. phaleth tailwind pretty much restricts code splitting
  25. blue yes
  26. blue btw, phaleth, within those nested elements, & refers to the parent element
  27. phaleth ok
  28. blue phaleth: ssh://gitea.repopack.app:2200/repopack/website.git
  29. blue or rather, the web address, I mean
  30. blue I shoved out a big updated, though it's not ready for deployment yet
  31. blue update*
  32. blue if you do wish to have a look at it locally, you need a local postgres db which you can configure in .env.local
  33. blue I got the git stuff mostly done for browsing files, now doing items / apps
  34. phaleth ok, is the update on master branch? looks like master is 1 month old
  35. blue yes. I've squashed and force-pushed, so it would show that way
  36. phaleth ah, ok, I see the nested css
  37. blue yeah, there's still a lot of nonsense I need to clean up
  38. phaleth well, I gotta figure out how to run rootful podman without sudo
  39. blue ya
  40. phaleth guess using tcp instead of unix sockets should do
  41. blue so once I finish the items view, I'll do the apps view. and then we'll need the podman api to work
  42. blue we also need ssh to work on port 22 on repopack.com
  43. blue that can happen later, but we do need it
  44. blue by which I meant git+ssh, using the git@ user
  45. blue so you can do `git clone git@repopack.com/primate/primate`
  46. blue I mean `git clone git@repopack.com:primate/primate`
  47. blue the rp repo itself will be under the repopack org, /web, I think
  48. blue then we can move everything else from gitea
  49. phaleth prolly only a git user is needed the, doesn't need to have sudo privs or really shouldn't need sudo privs at all
  50. blue yes
  51. phaleth cause ssh connectivity is available to repopack.com
  52. blue yes. we only need to figure how we map the paths, you know?
  53. blue so git clone git@repopack.com/repopack/web needs to map to wherever the repo is. and the problem is we need to check for permissions
  54. phaleth only haproxy comes to mind atm, cause ssh is tcp
  55. blue ugh, I keep writing / instead of :
  56. blue so we need to pass those git operations through a filter that checks against the db, that's the only difficult part
  57. phaleth check for permissions against database user?
  58. blue in the past, when I was doing adaptivecloud, I used the ssh2 package for it
  59. blue yes
  60. phaleth I mean, somebody stored in user tables
  61. blue you need to know if you have permissions to clone the repo / write to it
  62. blue for that, you need to query the postgres db
  63. phaleth ah, well, so you need a tcp proxy for node/deno
  64. blue probably, yes. because, we need to do this:
  65. phaleth cause dynamic processing is hard to do with haproxy
  66. blue someone uses git clone (or git push) -> we see a pubkey -> pubkey is in db -> we map pubkey to user -> we check if user has permissions to access the repo
  67. phaleth haproxy will just send the path to the tcp proxy behind it
  68. blue that's fair. the complexity is that haproxy needs to hand in the pubkey
  69. blue since that's the user identifier here
  70. phaleth if it's in a header then that's done automatically
  71. blue can haproxy do that?
  72. blue I don't think it's in the header, it's a tcp request
  73. phaleth oh, right, ssh
  74. blue it's part of the ssh protocol which extends tcp
  75. phaleth that means path is also not available
  76. blue this is one of the reasons I used https://www.npmjs.com/package/ssh2 for adaptivecloud
  77. blue but if you have a better idea, I'm open
  78. phaleth yeah, use a proper protocol instead of tcp
  79. phaleth haproxy will just had it over as tcp
  80. blue could haproxy forward the request completely to a backend running ssh2, *if* the user is git?
  81. blue that would be nice
  82. phaleth haproxy already does that for gitea
  83. blue ok, then that's what we're gonna do
  84. phaleth it's just the git user is within the gitea container
  85. blue we could have a git user inside the repopack/web container, too
  86. phaleth and so it could be the same for repopack I guess, just run the thing within container
  87. blue yes
  88. blue it would need to be an additional port exposed by the container, but that's ok
  89. phaleth the beauty of ssh is that it's already secure, so there is no need for haproxy to interfere with the traffic and so the repopack website app can do whatever it needs to do
  90. phaleth just like gitea does
  91. blue right. but the reason I was wary to use ssh2 was that it essentially reimplements openssh
  92. blue but if it runs inside the container I suppose that's ok
  93. blue we need programmatic ssh, either way
  94. phaleth well, if you really want port 22 then we can reconfigure the openssh server running on the host and put the alternative port number to our ~/.ssh/config on our client machines
  95. phaleth so that 22 is free for haproxy to use
  96. blue yes, that's the idea
  97. blue that way `git clone git@repopack.com:repopack/web` just works
  98. phaleth I did 2200 or whatever for gitea cause I don't think it should be made available to like normal public anyway
  99. blue yeah
  100. phaleth ok, configuring openssh server is easy
  101. blue cool
  102. blue btw, if you're testing the repopack repo locally, you can add this to your .git/config:
  103. blue [remote "local"] url = /home/blue/git/repopack/repos/primate/primate fetch = +refs/heads/*:refs/remotes/local/*
  104. blue (in 3 lines)
  105. blue and replace the url by your local path to the project
  106. blue then you boot up the app, create a primate namespace, create a primate project in it, then `git push local` inside your checkout of the primate repo
  107. phaleth might wanna add that to readme
  108. blue then you can see how it looks
  109. blue k
  110. blue will do shortly
  111. blue phaleth: I've pushed out instructions, tell me if it's coherent to you
  112. blue https://gitea.repopack.app/repopack/website#readme
  113. phaleth yeah, never tried devdb
  114. blue that's my tool
  115. phaleth I guess I should try to figure out the non sudo access to podman REST api first
  116. blue you can also just create a postgres container
  117. phaleth yeah :)
  118. phaleth blue: the podman API over TCP without sudo is available https://gitea.repopack.app/repopack/provision/commit/e191214fcf86efa04f2830ab1d048dc882c2d037
  119. blue phaleth: awesome!
  120. phaleth yeah, it's actually http, will be needed to control podman remotely
  121. blue cool

Search posts