WiiLink24 / production-deployment

In-use compose files for running versions of WiiLink24 services in production.
3 stars 2 forks source link

So spotlight, I made a auto-updater for this actually. #2

Closed ghost closed 3 years ago

ghost commented 3 years ago

https://github.com/WiiLink24-Extensions/git-pull-cron

Just one bug in the markdown, that's the only thing that isn't fixed. Everything else works great from what I can see from testing.

How to Compile

For compiling WiiLink24's custom version, you will need to install the FS module, follow the enviroment setup guide inside this README by clicking here and then do the following:

Returns: A Promise which resolves to the CronJob instance.

.jobs

The current list of CronJob instances that have been setup through init()

This is useful in case you wish to modify or stop cron jobs.

LICENSE

MIT - see LICENSE.md

I want to setup TwitchPlaysPokemon stuff only.

Then do...

mkdir /var/
cd var
mkdir other/
mkdir other/tpp
mkdir other/tpp/0
mkdir other/tpp/1
mkdir other/tpp/0/data
mkdir other/tpp/1/data
cd share
mkdir gitbot
git clone --recursive https://github.com/WiiLink24-Extensions/git-pull-cron gitbot/
cd gitbot

Then, to run the PBREngine 2.0 Updater, do:

cd /var/share/gitbot/
node pbrupdater.js
cd ../../../

Then, to run the TPPCore updater, do:

cd /var/share/gitbot/
node tppcore.js
cd ../../../

Please click here to view remaining instructions.

I want to setup WiiLink24 stuff only.

Then do...

mkdir /var/
cd var
mkdir schemas
mkdir share
mkdir schemas/vulcan/
mkdir share/wiinoma/
mkdir share/roomserver/
mkdir share/wiierd/
mkdir share/engine/
cd share
mkdir gitbot
git clone --recursive https://github.com/WiiLink24-Extensions/git-pull-cron gitbot/
cd gitbot

Then, to run the Vulcan Updater, do:

cd /var/share/gitbot/
node vulcan.js
cd ../../../

Then, to run the Wiierd updater, do:

cd /var/share/gitbot/
node wiierd.js
cd ../../../

Then, to run the Wii No Ma production code updater, do:

cd /var/share/gitbot/
node wiinoma.js
cd ../../../

Then, to run the Room Server updater, do:

cd /var/share/gitbot/
node roomserver.js
cd ../../../

Then, to run the File Maker Updater, do:

cd /var/share/gitbot/
node filemaker.js
cd ../../../

Please click here to view remaining instructions.

I wanna setup WiiConnect24 stuff only.

Then do...

mkdir /var/
cd var
mkdir schemas
mkdir share
mkdir schemas/vulcan/
mkdir share/engine/
cd share
mkdir gitbot
git clone --recursive https://github.com/WiiLink24-Extensions/git-pull-cron gitbot/
cd gitbot

Then, to run the File Maker Updater, do:

cd /var/share/gitbot/
node filemaker.js
cd ../../../

Then, to run the Vulcan Updater, do:

cd /var/share/gitbot/
node vulcan.js
cd ../../../

Then, it's up to you what to do next.


ghost commented 3 years ago

I have made some stability improvements Spotlight, I plan to shave off 0.2KB and then besides the markdown line issue, I will be ready 😄

larsenv commented 3 years ago

Shave off 0.2KB? What an improvement /s

ghost commented 3 years ago

Well Larsen, the original was around 16-20KB I think, and it is now 12.2KB, I just don't really have too many areas left to improve in :) I shaved off 1.2KB today I think, and yeah I am now at 12.2KB

ghost commented 3 years ago

The end goal is to be at 11KB.

ghost commented 3 years ago

@larsenv Would the file-maker script be of any use to ya? I mean, it might help you not have to do commits manually.

larsenv commented 3 years ago

no

Peter0x44 commented 3 years ago

what is the point of writing like this

spotlightishere commented 3 years ago

Hey, thank you for letting us know.

However, resources-wise, it'd be far lighter to pull via cron directly - the simple command of crontab -e to edit, its quite simple format, and https://crontab.guru can't get you wrong either going from there.

Additionally, I'm not sure it'd be in our best interest to pull the master version of software. Often this involves things such as database migrations that would have to be manually run. While this could be automated, I'd rather not risk production data somehow getting dropped due to changes that weren't fine-tuned upon commit. I think what we may end up doing is publishing tagged releases to ghcr and manually pulling from there, as eventually the structure of this repository will change to reflect changes made via the web panel and et cetera. Realistically the image builds fast enough that it wouldn't be remotely a pain to update whenever the team feels ready.

ghost commented 3 years ago

@spotlightishere I agree with that, maybe we can do internal software as well using Gogs, which then in turn we can do the same for the static repo? EDIT: We also might want to do deploy keys on our Gogs server in the event we ever do.

spotlightishere commented 3 years ago

I'm not sure I follow - why host our own git things?

(Also, Gogs is practically dead nowadays :( Definitely want to use Gitea!)

ghost commented 3 years ago

Oh, just for the private stuff, so we can update the private code, without needing a private Github repo :) As for gitea, yeah, I have been favoring it a bit too.

spotlightishere commented 3 years ago

Ah, I see. The end goal is to have everything public, as the only private assets currently existing are our own designs which haven't been automated via a panel/recorded by our DB to insert and render accordingly.

ghost commented 3 years ago

Alright :) Hey speaking of which Spotlight, had an idea for the glitch session. I am going to be deserializing the hardcoded data, and output it to a pickle .dat file. This hardcoded data mainly consists of the template HTML data and template subject, which my sendgrid script will be using. One of the things I am very curious about though Spotlight, is when we merge my WC24 stuff to Cacti, is it possible to have two mail servers on the same server? It's kinda been a thing I am pondering lately.

spotlightishere commented 3 years ago

I'm not sure why we would need two mail servers - feel free to email or message me individually to discuss as I don't want to pollute the notifications of those following this repo.