beneroth changed the topic of #picolisp to: PicoLisp language | The scalpel of software development | Channel Log: https://libera.irclog.whitequark.org/picolisp | Check www.picolisp.com for more information
clacke has quit [Read error: Connection reset by peer]
aw- has joined #picolisp
clacke has joined #picolisp
<Nistur> mornin' all
<Regenaxer> Hi Nistur!
<Nistur> I finally got around to starting to set up my new website. For now I'm still running on AWS because I'm going to make the most out of the 12 months free instance. I was looking into what I could do with pil, but came to the conclusion that I just want to put content out and every thing I tried sent me down a rabbithole that I really didn't have time for :'( I thought that using wiki might be good, but
<Nistur> there was some configuration which just wouldn't work on aws, whether this is because it's not able to use pil21, I don't know... I _am_ still using pil though, although only for the web server, hosting a static site for now. I may add more pil magic to it at a later date, once I have the content I need up and running though :)
<Regenaxer> ok
<Nistur> it's just got the directory with the static site allowed, so despite the fact that I didn't have a domain pointing at it until last night, I had something probing it, looking for php version etc. Now I have a domain pointing at it, I've got many many more trying to find admin.php etc... I've not even listed the domain anywhere, so they must be getting this directly from the registrar
<Nistur> it's made me sad that I have once again failed to get a pil project set up properly :( I always seem to find projects/environments with issues whenever I try. Doing more trivial tutorials etc work, but then as soon as I want to do more, I cause myself no end of problems
<Nistur> one day. One day.
<Nistur> I am using a static site generator in lisp, at least. Emacs lisp rather than picolisp, but that was because I decided I wanted something which would work quickly, and I just wanted to write the content in org-mode, as I like doing that, moreso than markdown or other similar solutions... but at least it's _some_ lisp, even if I didn't write it myself
<beneroth> Morning Nistur and Regenaxer :)
<Nistur> hullo :)
<Regenaxer> Cheers beneroth!
<Nistur> (I had also seen that there is stuff like... picoblogorg, which I will admit I didn't try, but that's because by the time I had got that far down that page, I'd had enough frustrations and just wanted to have something simple to start with)
<beneroth> re probing: scanning whole IPv4 range is easy and quickly doable this times, don't need anything pointing at your server.
<beneroth> so don't even try running somethig insecure on a "hidden" port
<beneroth> bots spam everything connected to the internet
<Nistur> I think the only thing running on the aws instance is an ssh server, which has passwords disabled, and pil on :80... technically that's bad as it's running as root and I need to look into... httpGate? but at the moment, I'm still mostly tinkering with this. I'm probably going to grab my site content files off, as they are just a git repo of plaintext files, then tear this instance down and start it up
<Nistur> properly, once I've figured out precisely what I want
<aw-> Nistur: beneroth: Regenaxer: hi
<Nistur> o7
<aw-> Nistur: i also generate html static blog from lisp (picolisp)
<Regenaxer> Hi aw-!
<aw-> much less hassle all around
<aw-> git push / git pull on the server to update the site
<Nistur> my plan is to make a post receive hook for git so that I can get the site to automagically update :P
<Nistur> how are you generating the static sites aw-?
<aw-> Nistur: parse a Markdown document
<Nistur> you wrote the generator then?
<aw-> Nistur: i dont use git hooks because i sometimes push branches and want to load the site from a different branch etc, safer to manually pull/checkout to update the site
<Nistur> I've done something similar, where I just had a specific branch as what the server was using, so that I could push whatever I wanted, and it didn't matter, but I had to merge to live and it would go up
<Nistur> I was seriously considering markdown, especially because of how ubiquitous it is at the moment, but I have written documents in org-mode for 15 years, and I am nicely set up for it, so I kind of wanted to go with that :P I am using weblorg as I just picked a random org-mode static site generator and that one 'just worked' which is enough for me right now
<Nistur> this is mostly because I'm considering looking for more work, and my CV points to my website for more info. My website's been down for... months. It was using an ancient version of wordpress, semi broken from the last time I tried to update it. I couldn't be bothered to try to rescuscitate it... but I needed something to point the CV to... so I want to quickly throw up something as a CV extension
<aw-> i see
<aw-> use whatever works best for you and is 'simple'
<Nistur> someone asked me if I had considered just putting up a wix site and... yes... that would solve the problem, but as it's meant to be a CV extension... and my CV is... esoteric and awkward, I think it'd be off-brand if I did that :P
<aw-> oh please stay away from wix
<aw-> what a horrible platform
<Nistur> I currently have no intention to get a wix site :P
<Nistur> I worked for a startup that used a site on that platform, albeit a few years ago now, and they had a whole world of pain with it
<aw-> ok so your problem now is just getting SOMETHING up
<aw-> 1) don't yak shave
<aw-> 2) use decent existing tools that won't "lock you in" in the long-term
<aw-> 3) done
<Nistur> I have far too many yaks as it is :D
<Nistur> but yeah
<aw-> i can recomment Bootstrap with a free theme
<aw-> you can strip off 95% of the crust from those free themes
<aw-> remove all javascript and unused CSS
<aw-> then throw your CV on there
<Nistur> I mean, my CV is hosted on github :P https://github.com/nistur/cv/releases/tag/1.2.0 It's literally just the "for more information on this project, click here" kind of info that I want to host... and I know that there isn't _that_ much on my CV, that's because the only times I've updated my CV before is when I've been made redundant, so I've had limited time, and _not_ written that information... but
<Nistur> I've always intended to go back and fill in the bits I missed
<Nistur> this time though, I'm fed up with this job, so I have more time and flexibility
<Nistur> and, like I said, esoteric and awkward, so yes, my CV is available as a manpage
<Nistur> and an executable
<Nistur> because why not :D
<aw-> great
<Nistur> one of the reasons for using org-mode as the website content source, rather than markdown is that I can in future merge the repositories, and have my CV output as a page on the site too
<Nistur> but that's not a now-job, as I don't really want to have to worry about making it work with two export paths right now
<aw-> i dont see why you would change your current approach now
<aw-> seems to work fine
<Nistur> :)
<beneroth> 'wix' is 'to wank' in german
<Nistur> haha
<Nistur> hmmm, when using httpGate, I don't have the ability to blacklist/whitelist directories, so if I start it, like the example, pointing at the home directory, I can easily snag files from it
<Nistur> which is... less than ideal
<Regenaxer> This is not an issue of httpGate
<Regenaxer> but (allow)
<Regenaxer> allow / allowed / *Allow
<Nistur> yes
<Nistur> I haven't yet figured out how to use that in this setup
<Regenaxer> It has now blacklisting. If there is any call to allow, it does whitelisting
<Regenaxer> files, directories or functions
<Regenaxer> Perhaps look at the demo app/ ?
<Regenaxer> : (doc 'allowed)
<Regenaxer> Basically only (allowed ..) is needed
<Nistur> ok :) thanks
<Regenaxer> welcome :)
<Nistur> I didn't understand allowed et al when I was reading up on it, and assumed it had to be done in the server setup
<Regenaxer> yes, in the server
<Nistur> I think if I just set the working directory to be the http root, it should be fine? Maybe?
<Regenaxer> Hmm, which root?
<Regenaxer> You have a current working directory
<Nistur> I have the static site generated to ~/site/output
<Nistur> so I have names setting that to the working directory
<Nistur> and put index.l in that
<Regenaxer> yes, good
<Nistur> which for now just has (in "index.html" (echo))
<Regenaxer> So the pathes allowed are relative to that
<Nistur> which lets me use the static site for now, and then build on it when I have time :)
<Nistur> but nothing above it though, right?
<Regenaxer> yes
<Nistur> cool, that should be secure enough then I guess :P
<Regenaxer> ".." in path names is disallowed
<Regenaxer> yes
<Nistur> as I said before, I'm still messing around a bit with this. I think when I do this properly, I'll have the the server running on a separate user that can just serve the site(s)
<Nistur> but for now, this'll do :)
<Nistur> next job: figure out certbot so I can get that -s in my http :P
<Regenaxer> yeah
<Regenaxer> I used --standalone for certbot
<beneroth> I don't like this bloated thing, but it works and is probably the most updated LE client...
<Regenaxer> Is it bloated? I never really checked. Just called the 'certbot' script
<Regenaxer> Also in a weekly cron job
<beneroth> it is rather big and it requires python etc. installed
<Regenaxer> ah, right, python
<Regenaxer> shudder
<Nistur> ... I have {firstname}{surname}.co.uk and {firstname}{surname}.com and I forgot to point the latter to the same server, so now I'm going to have to wait for DNS to propagate so I can get the cert to match both
* Nistur sighs
<Nistur> Regenaxer: going to write your own in pil? :P
<Regenaxer> No plan :)
* beneroth thought about it, but didn't do it yet, and is a bit afraid of having to adjust it then all the time when they change the API, which they sometimes do...
<Nistur> [INSERT SHIA LEBOEF HERE]
<beneroth> haha, nice
<Nistur> LEBOEUF?
<Nistur> whatever
<beneroth> I got the reference ;-)
<Nistur> LABOEUF
<beneroth> "you can't just put "le" in front of something to make it French" - "Le shut up" :D
<Regenaxer> :)
<Nistur> you can't make it french
<Nistur> but you can make it sound le french :P
<Nistur> boom. https now works
<Nistur> wondering if I still need a http server too
<Nistur> looks like starting httpGate with both 443 and 80 'just works', so it doesn't try and run the server twice at :8080?
<Regenaxer> right. Your server listens at 8080, just once
<Regenaxer> httpGate routes both 80 and 443 to 8080 then
<beneroth> Nistur, you have firewall/iptables rule to deny public access to 8080 ? :)
<Nistur> sounds good to me :P While I'll link https anywhere, and I have https everywhere in all my browsers, I shouldn't need http, but as this is primarily for expanding on my CV, I don't want to have the option for a potential employer not being able to get to my site :P
<Nistur> beneroth: aws requires specific whitelisted ports, so I think all that is open is :80 and :443
<beneroth> ah good
<Nistur> trying to go to :8080 in a web browser doesn't seem to do anything at least
<beneroth> yeah. maybe possible from another AWS server in same LAN, but probably not :P
<Nistur> I think even that probably won't
<Nistur> I think you need to create pools of instances and then routes between them
<beneroth> yeah, probably not at AWS. with other hosters I would not rely on it :D
<Nistur> (I should know this, I'm doing it for one of my work projects)
<beneroth> aye, AWS ha surely virtualized everything 5 times
<beneroth> "you cannot hack me, I'm behind 5 vlans" :D
<beneroth> Patrick: "spectre and rowhammer" SpongeBog: "don't say that Patrick, that ruins the whole cloud business model"
<Nistur> I'm currently running on AWS to take advantage of the 12 month free t2.micro instance :P But I'll probably move it to my friend's hosting box eventually. He runs slackware UK and has offered me hosting. Main problem is, I don't think there's a slackware package for pil :P
<Nistur> so while I'm waiting for him to decide whether he wants to make an official picolisp package, or what, I'll tinker with this
<beneroth> well ok, building is slightly more involved.. but really not much
<Nistur> while he's _probably_ ok with me doing that, the issue is then if there are more version compatibilities, like I had with AWS... I'd prefer, if he can get around to it, to make an official package, and ensure everything 'just works' :P
<beneroth> it surely would lower the barrier for slackware users to get into picolisp :)
<Nistur> yus :P
<Nistur> I'm pretty happy that I have the site running now though, and with https :D tonight I might tidy up the users etc, then I can (finally) get around to actually writing content for it :P
<beneroth> gz :)
aw- has quit [Ping timeout: 240 seconds]
rob_w has joined #picolisp
rob_w has quit [Quit: Leaving]
<razzy> Hello, how do i delete safely from picolisp database? whole external symbol and +Joint relation separately?
<Regenaxer> Basically you lose!> the Entity object
<Regenaxer> and call (dbgc) later
<Regenaxer> But there is no guarantee that it is really removed, cause it may be referenced otherwhere
<razzy> thx.
<Regenaxer> For example, +Joint behave so that all links *to* that object are cleared in lose>
<Regenaxer> but not links *from* it
<Regenaxer> lose> also un-indexes the object
<Regenaxer> but it may still be referred to
<Regenaxer> Depends on the model
<razzy> lose!> works on relations. If I want to delete {X}, i need to loose all references and than dbgc, am I correct?
<Regenaxer> You can further control the behavior with prefix classes in the relations
<Regenaxer> No, lose!> works on +Entity
<Regenaxer> the entity then sends lose> ti the relations
<Regenaxer> s/ti/to
<razzy> i read doc :]
<Regenaxer> So (lose!> '{X}) is fine
<razzy> on lose
<Regenaxer> (vi 'lose> '+Entity) :;
<razzy> no doc on lose?
<Regenaxer> yes
<beneroth> documented on +Entity
<razzy> lose1> delete one relation. correct?
<razzy> one +Joint
<Regenaxer> yes, one relation
<Regenaxer> typically in another entity relating the current one
<razzy> Thank you :].
<Regenaxer> Not sure if lose1> is really useful
<Regenaxer> I needed it very seldom iirc
<beneroth> I never used it, I think
<beneroth> razzy, if you just want to delete the connect, then use (put> 'obj 'prop NIL) which is the same as (put> 'obj 'prop NIL)
<Regenaxer> ?
<razzy> beneroth: not sure how other side of Joint will behave
<beneroth> it will be NILed too
<beneroth> if its a list, then the related entry will be removed
<razzy> beneroth: are you sure?
<Regenaxer> So lose1> is only useful for +Joint probably
<Regenaxer> at least I find no other use case here
<beneroth> yeah. That is the point of +Joint. You only need to add a value to one end, the other gets updated automatically. Same with removal.
<beneroth> @razzy
<beneroth> Regenaxer, I guess so...
<Regenaxer> yes, exactly
<Regenaxer> the point of +Joint
<Regenaxer> may be +List on one or both sides
<beneroth> T
<razzy> i see
razzy has quit [Ping timeout: 240 seconds]
razzy has joined #picolisp
razzy has quit [Ping timeout: 252 seconds]
razzy has joined #picolisp
razzy has quit [Ping timeout: 250 seconds]
razzy has joined #picolisp
razzy has quit [Ping timeout: 250 seconds]
razzy has joined #picolisp
beneroth_ has joined #picolisp
beneroth has quit [Ping timeout: 256 seconds]
razzy has quit [Ping timeout: 256 seconds]
razzy has joined #picolisp
razzy has quit [Ping timeout: 252 seconds]
beneroth_ has quit [Quit: Leaving]