wiki-v1 icon indicating copy to clipboard operation
wiki-v1 copied to clipboard

Not pushing to git?

Open madchap opened this issue 7 years ago • 5 comments

Using latest docker image, through docker-compose. Site works fine.

Actual behavior

Upon saving, nothing gets pushed. Nothing in the container logs.

If I exec into the container, git works (eventually after a git pull --allow-unrelated-histories), I can git push and all. Local git changes are well there, as a git log can attest.

There seems to be no action whatsoever with git backend.

git:                                                                                                                           
  url: [email protected]:myrepo/wikijs.git
  branch: master               
  auth: 
        
    # Type: basic or ssh
    type: ssh          
        
    # Only for SSH authentication:
    privateKey: /etc/wiki/keys/git.pem
        
    sslVerify: true  
        
  # Default email to use as commit author
  serverEmail: [email protected]
        
  # Whether to use user email as author in commits
  showUserEmail: true  
        
  signature:         
    name: Fred Blaise
    email: [email protected]

Expected behavior

Upon saving, my changes are pushed.

madchap avatar Oct 31 '18 11:10 madchap

So it seems to now be automagically work now? hmmm. Looks like halloween did its thing.

madchap avatar Oct 31 '18 17:10 madchap

Actually, re-opening -- maybe for a feature request?

Is it really doing its thing every 5mn, and not being event-based on save?

madchap avatar Oct 31 '18 19:10 madchap

No, this is by design. While all commits are event based, the sync is done periodically as it's a network intensive operation.

v2 will likely have a setting to set the sync delay, but doing a sync on every event is not a good idea.

NGPixel avatar Oct 31 '18 23:10 NGPixel

Is it mandatory for private key to be in .pem extension/format? Following is my configuration but it doesn't push anything to git. Also deploy key is added in the repository with write permission

git:
  url: [email protected]:myrepo/wiki.git
  branch: master
  auth:
    # Type: basic or ssh
    type: ssh
    privateKey: ./keys/wikijs_rsa
    sslVerify: true

  signature:
    name: 'John Doe'
    email: [email protected]

  # Default email to use as commit author
  serverEmail: [email protected]

  # Whether to use user email as author in commits
  showUserEmail: true

johnshumon avatar Nov 04 '18 21:11 johnshumon

@johnshumon The key can be in any file extension (or not at all). However, the format must be a valid one accepted by git ssh.

NGPixel avatar Nov 13 '18 16:11 NGPixel