Comments (3)
From the documentation, it seems that the $HOME
is defaulted to /var/www/__APP__
in Yunohost (see here). This is also the default value of __INSTALL_DIR__
(see here).
In https://github.com/YunoHost-Apps/gogs_ynh/blob/master/conf/app.ini#L63 we have
; The path of SSH root directory, default is "$HOME/.ssh".
SSH_ROOT_PATH =
And in the service config:
HOME=__DATA_DIR__
I think it should be HOME=__INSTALL_DIR__
instead, to be consistent with yunohost config.
I'm would enjoy any feedback on this, and any clue on how to test this properly (I have not yet attempted to develop anything on yunohost, so any pointers to try this quickly would help)
from gogs_ynh.
I issued the command sudo ln -s /home/yunohost.app/gogs/.ssh /var/www/gogs
.
This fixed the issue for the key authentication. I am now connected to ssh.
But another problem occures:
matthias@matthias-pc:~/inria/redaction$ git push
Debian GNU/Linux 11
fatal : Error: fatal: protocol error: bad line length character: This
This thread is useful for debugging.
It leads me to issue the following:
$ ssh gogs@<server> git-receive-pack /home/yunohost.app/gogs/repositories/matthias/<my_repo>.git/
Debian GNU/Linux 11
This account is currently not available.
$
From this other thread it looks that the gogs user being setup as "nologin" causes this issue.
My question now is the following: should the git user be setup as nologin, for enable ssh correctly ?
from gogs_ynh.
This is fixed with changing the shell of user "gogs" from /sbin/login
to /bin/bash
(I first tried with /usr/bin/git-shell
, but this fails due to gogs using specific command along with the key, command that is not available with git-shell
).
You can make this change with
sudo usermod gogs --shell /bin/bash
And now it works well:
$ git push
Debian GNU/Linux 11
Everything up-to-date
Two remarks:
- Did I enable any unnecessary security hole by doing this ?
- Is it the correct shell to use ?
from gogs_ynh.
Related Issues (20)
- Backup/restore issue HOT 5
- private mode does not work HOT 7
- Upgrade issue HOT 4
- Many requests from outside HOT 3
- Add check process HOT 1
- Permission denied
- Add rsync HOT 1
- Error 500 on install HOT 2
- Backup from ARM and restore on 64bits
- 500 error, not sure how to fix HOT 7
- Update to 0.11.29 HOT 4
- Error Redirect HOT 8
- Your app is out of date on the community list HOT 1
- Commit is not up to date in the community.json HOT 2
- Can't disconnect using the disconnect button of gogs HOT 3
- Update to version 0.11.53 HOT 2
- [Maintenance ping] Is this app still maintained ? HOT 1
- Cannot upgrade to version 0.12.3~ynh1 HOT 4
- Can not clone with SSH: AllowGroups
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gogs_ynh.