Some short term goals

Forums Goals, To do lists, etc. Some short term goals

This topic contains 11 replies, has 1 voice, and was last updated by  Josh January 8, 2017 at 9:04 am.

  • Author
    Posts
  • #60

    Josh

    Looking into what’s available in open source for interacting with git through PHP.

    Clearly, there is no problem with simply running shell commands from a chron job or logged in via ssh, but being able to do some management/inspection from the web is desirable in the context of how I plan to use Dreamhost – i.e. one WordPress web interface per rooted directory tree.

    Potentially useful:

    Gitlist – https://github.com/klaussilveira/gitlist – looks like it is a browser & not an admin tool, but the browsing is the meat part of the development…launching commands from a interface is relatively a lot simpler, though one would probably want the command to be connected to the thing being browsed in the ideal case, rather than requiring copy/past.

    GitPHP – https://gitphp.org/

    Git.php – https://github.com/kbjr/Git.php A PHP wrapper for the shell commands Maybe some use in conjunction with other sources.

    Stack overflow article about using git with MySQL discusses WordPress issues: http://stackoverflow.com/questions/13608706/using-version-control-git-on-a-mysql-database

    This article discusses a crude way to copy a WordPress blog post from a local machine to a remote WordPress installation via git (or mercurial), working through a central repository on bitbucket:
    https://code.tutsplus.com/articles/how-to-sync-a-local-remote-wordpress-blog-using-version-control–wp-22135

    Reading these two articles, the correct form of the solution is apparent:
    1) Under source control, one should have a method for listing relevant parts of a given site MySQL database
    2) The output of that tool/process should be under source control
    3) For each part in that listing, mysqldump of the part in relevant format should be under source control
    4) Syncing should work and log by detecting which parts update

    The above is obvious enough that someone must have implemented it already. One problem though is that database logic is potentially complicated enough that only a complete database restore works…implying that the complete database dump would need to be in source control anyway, making table by table superfluous except for info. That complex case does not happen with pure WordPress because it keeps the same tables/meta-data. Could happen with some plugins or other development, though it would not normally unless they use special database cross-table references. So maybe have two processes, with the full one only running when/if that is detected…?

    This article discusses MySQL backup option which uses single inserts rather than bulk statements:
    ww.viget.com/articles/backup-your-database-in-git

    Can those two cases be mapped onto branch/release logic? -e.g. once in a while sync back up to the full dump as a stable point and only include increments after it?

    Relevant: https://www.axllent.org/code/phpmybackup/

    Database Versioning with DBV

    This tool is concerned with problem of keeping target DB up and running while updates that might involve schema changes are happening:
    https://github.com/github/gh-ost

    • #61

      Josh

      That was interesting to see that link expanded inline. Not sure why that happened or what controls it. Note to self: investigate!

    • #68

      Josh

      Seems that the most straightforward solutions can take advantage of WordPress special situation – using MySQL or compatible as DB, and WordPress itself is the only important user of its own DB with a REST interface.

      So live Restore can work by restoring first to a substitute copy target and then doing a hot swap to quickly point WordPress at the substitute. Similarly, copying to a substitute and then doing a full dump may give better “live” performance than doing a full dump directly, especially with the DB on a different IP as is the case with Dreamhost.

      Planning to do things that way, we can divide the backup & restore of the database portion as a full logical backup of the substitute copy followed by the appropriate hot swap. Apparently, MySQL also has a slave option so that the substitute already exists. Not sure if this can be enabled on the shared hosting, but creating it shouldn’t be a big drain for a WordPress site in any case.

      http://stackoverflow.com/questions/67093/how-do-i-quickly-rename-a-mysql-database-change-schema-name?rq=1

      http://stackoverflow.com/questions/18235040/swapping-toggling-two-mysql-databases

  • #69

    Josh

    Mostly worked on figuring out my website backup solution today. Will eventually be automated as a cron job for both web code and database files. Will use git to store both with efficient versioning. Scripting should be straightforward. I did the first version by hand today and pushed the initial git repository to Bitbucket. Another advantage of this, besides versioning, is that it makes it easy for me to move and sync files between local development and different servers.

    One surprising and annoying local problem involves my new USB keyboard not waking up after suspend to RAM (it it is fine on warm or cold boot). Examination of linux logs and online search seems to indicate the problem is with Linux kernel USB logic that goes into a kind of erroroneous cul de sac when a device doesn’t respond properly or quickly enough on power up initialization. Recommended solution seems to be configuring a kind of local message to tell the Linux kernel that this particular device is quirky and should be tolerated as such. I tried to copy the online suggestion, but haven’t determined yet whether it solves my problem.

    Plan to set up a web devel environment on my local machine that mirrors the remote one. Downloaded eclipse-PDT which seems to be the most recommended. Working on making a junky local CA certificate so I can run https through Apache in a way that’s parallel to the remote sites. Most fundamental benefit will be the ability to step through server side PHP in a debugger.

    Picked up 10 books that I requested from my local library system as part of my literature review.

  • #668

    Josh

    …feels like a required course in my current curriculum. Difficult to skip. Not already learned.

    • #669

      Josh

      U were the first person to point out to me the FBI’s “MLK, you must go commit suicide” letter.

      I understand how to put the current abuse patterns in context. It’s only the EMF torture/health hit/distraction that really means anything, but getting around & through that is a daily/monthly/yearly/ongoing struggle.

  • #670

    Josh

    I feel like this house should be active as a commercial property and situated at the bottom of a hill in a mountainous region. Does that check out?

    • #671

      Josh

      The literature I have read leads me to believe that witnesses and especially active “whistleblowers” and umpires are the FBI’s favorite targets. Whatever cult ideologies they may or may not have – e.g. about their radical right wing politics – it’s secondary to that.

      • #673

        Josh

        Do some FBI folk actually think it was wrong for me to talk to one of their fakes one day while he had fake children around?? While you are killing me, that inconvenienced you? If true, that’s remarkable hubris, and I’d point out, that obviously it was your play to call the local police…an act which affected you all more than me…

  • #770

    Josh

    Why have I prioritized reading, note-taking, reference citing, storing web materials, and some blog commenting over programming recently? Mainly a) the reading/note taking I wanted to do emerged as a big chunk of time/cost so I’ve been trying to go through public library books before I have to return them – I feel like I’ve been getting a lot of good progress from that, b) a lot of times, while going through a book that references other material, I end up going to another secondary source and then to primary sources – and then I try to save those – that chain takes time, c) programming is hard to work at without having several hours of concentrated focus on a particular task in a given day, so it often becomes the main thing if is to be a productive thing at all – u were complaining that I was too mute & unwritten when I focused on programming as the main thing, and I felt that was true as well, d) I’m a bit non-plussed by the feeling that getting any kind of decent static lint checking with PHP means subscribing annually to the proprietary PHP Storm – maybe I’ll bite the bullet, but it seems like a shame that the market converged that way rather than on some shared infrastructure solutions. I’ll probably get back to it soon, e) JFK case is a well recognized time sink – there are real, intrinsic, rather than silly reasons for that.

    No unique or path-turning reason.

    • #775

      Josh

      The reality is that I am in a super tough spot because most people I need to help me are in an information position – their current combination of true and false beliefs – where it is rational for them to disbelief most of the things I have to say that would lead them to help me in some way. It’s tough to maneuver out of a death trap like that with the FBI spending whatever it takes to make sure one fails. Calling progress “slow” there is a bit like calling Sisyphus someone who has an issue with finishing tasks. It’s true, but there are reasons…

You must be logged in to reply to this topic.