-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Proposal/RFC] Adding support for local git repositories #86
Comments
It would be great to have a way to commit to local git repositories.
I'm not entirely clear on the relationship between the (local) website
and its (local) git infrastructure. Is the intention that the local web
server will "speak git" and provide an api like github does for
commits/pull requests? Will it be the same api as github's, or some
other standard api? If not, then any back-end you develop will only
work with your (nonstandard) api---which might be all you need but won't
be generalizable.
…On 1/31/2021 4:36 PM, Adrian C. Edwards wrote:
Mavo seems nearly perfect for my usecase, however for one website that
I'm planning to use Mavo with, I'd rather not have a public github
repository (or make the client sign up to github).
I wanted to make this feature proposal as a sort of
Request-For-Comment to see if creating a new storage backend based on
the github one, but intended for local git repositories (i.e. where
the git repository is stored on the same server that is hosting the site).
I imagine this would act exactly like the github integration but would
make the commits to either a repository in the current directory, or a
more custom setup with a bare repository in another folder (using git
worktree) so that the .git folder is not being served by the web
server. This would allow a local git username and email address to be
set up for use as the identity for making commits so that git is
completely abstracted away from the end user (such as when a developer
is setting this up for a client).
To replace the github auth (and thus continue to control who is able
to make changes to the repository) i was thinking of either setting up
some local login database that could run on the webserver to provide a
login functionality, or possibly using some kind of oauth (like sign
in with google) so the user is able to make edits if they successfully
complete a "sign in with google" exchange and authenticate as an
account that is on a predefined list of allowed editors (and possibly
mapped to git commit identities).
While I should be able to make this happen myself by reading the
awesome docs on olugins and storage backends, I'm pretty much brand
new to Mavo and wanted to see if the community had any feedback on how
to do this (or if anything can be added to help it benefit the
community even further)
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<https://github.com/mavoweb/mavo/issues/685>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIWSXSU6PULJPOVBEWMNCDS4XEN7ANCNFSM4W3XUGDA>.
|
Let's take a step back for a moment. You mention that you don't want your client to have to sign up to Github, and also that you want the data to be private. Then you suggest Mavo writing to a local git repository as a solution to these issues. Are there other reasons you want a local git repo as a backend? Because for the two issues you mentioned, there are many other solutions. First, the data doesn't have to reside in a public repo, a private repo works fine. In that case however, one would need to be logged in to view the data. A workaround for that would be to use To avoid your client signing up to Github, you could use any of the other backends: Dropbox, Google Drive, Firebase etc. However, if you were going to set up a local git repo and do all the things you describe to log your client in, you may as well register for them on Github and log in for them.
It's 99.9% frontend code. There is a server component to authenticate with some of the APIs. |
here are some different methods I was thinking of for achieving this:
|
@LeaVerou Whoops. didnt see your message above when i posted my last one. The web server is currently set up with staging and production versions of the site as different branches so I probably could find a way to use a storage backend like GitHub or Gitlab (Gitlab offers sign in with google .etc) and just have give each branch a different It seems like GitLab support via a plugin be something would be helpful for this and other users as well. Would these be featured that would be helpful (either as plugins or pull requests)? While not the most practical solution, I did also find https://plugins.mavo.io/plugin/php that seems to follow a very similar architecture to my initial proposal and could likely be adapted to work with and commit to a local git repo or worktree for people with different requirements. |
Mavo seems nearly perfect for my usecase, however for one website that I'm planning to use Mavo with, I'd rather not have a public github repository (or make the client sign up to github).
I wanted to make this feature proposal as a sort of Request-For-Comment to see if creating a new storage backend based on the github one, but intended for local git repositories (i.e. where the git repository is stored on the same server that is hosting the site).
I imagine this would act exactly like the github integration but would make the commits to either a repository in the current directory, or a more custom setup with a bare repository in another folder (using git worktree) so that the .git folder is not being served by the web server. This would allow a local git username and email address to be set up for use as the identity for making commits so that git is completely abstracted away from the end user (such as when a developer is setting this up for a client).
To replace the github auth (and thus continue to control who is able to make changes to the repository) i was thinking of either setting up some local login database that could run on the webserver to provide a login functionality, or possibly using some kind of oauth (like sign in with google) so the user is able to make edits if they successfully complete a "sign in with google" exchange and authenticate as an account that is on a predefined list of allowed editors (and possibly mapped to git commit identities).
While I should be able to make this happen myself by reading the awesome docs on plugins and storage backends, I'm pretty much brand new to Mavo and wanted to see if the community had any feedback on how to do this (or if anything can be added to help it benefit the community even further). From my research so far, it seems like, most critically, this would depend on the ability of Mavo to run git comands (or other system commands) on the web server. Does Mavo's achitecture have a server side/backend component, or is it all frontend node?
The text was updated successfully, but these errors were encountered: