Building for MLP Forums... or at least trying to! by DDR (#PonyDev @ Everfree Northwest 2018)

Building for MLP Forums... or at least trying to! by DDR (#PonyDev @ Everfree Northwest 2018)

A 10 minute lightning talk from Everfree Northwest 2018's Pony Programming panel. Find more slides at https://developer.horse

Presented by DDR

D6e6de8a5d1bd38cb31b668209d956ce?s=128

Inky Collective

May 19, 2018
Tweet

Transcript

  1. 2.

    2 Needless to say... This talk is not endorsed by

    or representative of my employer or Poniverse. The images contained in this talk are probably property of their artist, their owner, or Hasbro.
  2. 4.

    4 Why am I the admin? (No, seriously, why am

    I the admin?) - Drinking? - Right person, right place. - I met one of the main guys behind Poniverse, Feld0. - Not a lot of competition for the job. - Skilled, yet unpaid and unexciting.
  3. 5.

    5 So I'm the admin. But I don't know anything

    about running MLPF. Nor does our wiki:
  4. 6.

    6 So I'm the admin. But I don't know anything

    about running MLPF. Step 1: Get the forums running locally on my machine.
  5. 7.

    7 So I'm the admin. But I don't know anything

    about running MLPF. Step 1: Get the forums running locally on my machine. Step 2: Fix things on my local machine, then fix things in production after I've figured them out.
  6. 8.

    8 So I'm the admin. But I don't know anything

    about running MLPF. Step 1: Get the forums running locally on my machine. Step 2: Fix things on my local machine, then fix things in production after I've figured them out. Step 3: Ponies?
  7. 15.

    15 The Second Attempt Let's install a VM! - They're

    safer. Everything's contained. - Smaller chance of taking out the host OS.
  8. 16.

    16 The Second Attempt Time to install - Ubuntu -

    Linux, Nginx, MariaDB, PHP - The requirements for IP.Board. - and, finally, IP.Board itself.
  9. 17.

    17 The Second Attempt Time to install - ubuntu package

    manager: installed the synaptic package manager - synaptic: installed mysql-server, nginx, php-fpm (as opposed to php-cgi), and available updates. - mysql password is same as server - tweaked nginx, roughly according to https://www.digitalocean.com/community/tutorials/how-to - installed gksu for properly-permissioned graphical shell sudo powers - ran sudo chmod 644 * -R in /var/www/html, since the files couldn't be read by www-data (which i - now the site runs, displaying a 'down for maintenance' message. - commented out ~/index.php's 'remote addr' check, which forces the maintenance page - Installed PHP extensions required by ips4.php, IPS Community Suite compatability checker. Usin - link: https://invisioncommunity.com/files/file/7046-get-ready-for-ips-4/ - synaptic: installed php-curl, php-xml, php-gd, php-mbstring, php-mysql, and php-zip. - > sudo apt install php-curl php-xml php-gd php-mbstring php-mysql php-zip
  10. 18.

    18 The Second Attempt Now the base thing works. -

    We've got a vanilla installation of IP.Board. - Install the addons, we can load the DB up with some data and we're good right?
  11. 19.

    19 The Second Attempt Now the base thing works. -

    We've got a vanilla installation of IP.Board. - Install the addons, we can load the DB up with some data and we're good right? - Wrong.
  12. 20.

    20 The Second Attempt Now the base thing works. -

    We've got a vanilla installation of IP.Board. - Install the addons, we can load the DB up with some data and we're good right? - Wrong. - Install the MLPF-tweaked PHP files, and we're good right? - Wrong. - But not tooo wrong... - On to the next problem!
  13. 21.

    21 The Second Attempt Time to get all the database

    in there. - We only have a small sample right now.
  14. 22.

    22 The Second Attempt Time to get all the database

    in there. - We only have a small sample right now. We'll get the data from the server... - And take down the server for 20 minutes.
  15. 23.

    23 The Second Attempt Time to get all the database

    in there. - We only have a small sample right now. We'll get the data from the server... - And take down the server for 20 minutes. ... and load it in the database.
  16. 26.

    26 The Second Attempt So, we talk a lot. -

    Like, a lot. - Like, more than a default VirtualBox VM's hard disk can hold.
  17. 27.

    27 The Second Attempt We must go bigger! - Resize

    the virtual disk drive! - No. The VM mysteriously won't load now. - Delete the snapshots, then resize the VDD!
  18. 30.

    30 The Second Attempt So, we talk a lot. -

    Like, a lot. - Like, more than my computer's SSD can hold.
  19. 31.

    31 The Second Attempt We must go elsewhere! - Ctrl-c

    ctrl-v to the main disk drive from the SSD. - Slower, but it works! - md5sums match. Can never be too paranoid... - Delete the copy on the SSD so my stuff works again. - Ctrl-c ctrl-v a backup. - $ cp Poniverse-MLP-Forums.vdi Poniverse-MLP-Forums.vdi.bak
  20. 32.

    32 The Second Attempt We must go elsewhere! - Ctrl-c

    ctrl-v to the main disk drive. - Slower, but it works! - md5sums match. Can never be too paranoid... - Delete the copy on the SSD so my stuff works again. - Ctrl-c ctrl-v a backup. - $ cp Poniverse-MLP-Forums.vdi Poniverse-MLP-Forums.vdi.bak - cp: error reading 'Poniverse-MLP-Forums.vdi': Input/output error
  21. 33.

    33 The Second Attempt We must go elsewhere! - Ctrl-c

    ctrl-v to the main disk drive. - Slower, but it works! - md5sums match. Can never be too paranoid... - Delete the copy on the SSD so my stuff works again. - Ctrl-c ctrl-v a backup. - $ cp Poniverse-MLP-Forums.vdi Poniverse-MLP-Forums.vdi.bak - cp: error reading 'Poniverse-MLP-Forums.vdi': Input/output error
  22. 34.

    34 The Second Attempt OK, try to back up again.

    - $ rm Poniverse-MLP-Forums\ Clone\ 2 -r - rm: cannot remove 'Poniverse-MLP-Forums Clone 2': Read-only file system
  23. 35.

    35 The Second Attempt OK, try to back up again.

    - $ rm Poniverse-MLP-Forums\ Clone\ 2 -r - rm: cannot remove 'Poniverse-MLP-Forums Clone 2': Read-only file system Uh oh.
  24. 36.

    36 The Second Attempt The drive is dead. - It's

    truly not coming back. - A solid month's work is down the drain. - And my computer won't boot.
  25. 37.

    37 The Second Attempt At least we have backups... -

    Of everything but the VM. - It was so big... - So, buy a new HDD. - Redo the work on the MLPF VM quickly, from the notes in the backup. - About two weeks later, we're back to where we were. - Things are working a little better now, at least. I was able to correct some of my previous mistakes, like installing wrong DB again.
  26. 40.

    40 The Second Attempt So now we've got everything working?

    - Yes. Ish. - The VM dev install is still flakey enough that I can't be sure whether an upgrade has broken anything, or if it's just the dev install being flakey.
  27. 41.

    41 The Second Attempt So now we've got everything working?

    - Yes. Ish. - The VM dev install is still flakey enough that I can't be sure whether an upgrade has broken anything, or if it's just the dev install being flakey. So it's basically useless.
  28. 42.

    42 The Third Attempt Coming soon: I try to install

    Docker. - We have an old image I can use. It was known to work at the time it was made.
  29. 43.

    43 The Third Attempt Coming soon: I try to install

    Docker. - We have an old image I can use. It was known to work at the time it was made. - I've never used Docker; and this is a fairly complex, mostly undocumented project.
  30. 44.

    44 The Third Attempt Coming soon: I try to install

    Docker. - We have an old image I can use. It was known to work at the time it was made. - I've never used Docker; and this is a fairly complex, mostly undocumented project. - So, basically, wish me luck and I'll tell you all how this went next year!