Skip to content
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

When i run 'git push -u origin master' will get this error message:'pre-receive hook declined' #3019

Closed
2 of 7 tasks
Mr9esx opened this issue Nov 29, 2017 · 5 comments
Closed
2 of 7 tasks

Comments

@Mr9esx
Copy link

Mr9esx commented Nov 29, 2017

  • Gitea version (or commit ref):f148a4a
  • Git version:1.9.2
  • Operating system:Ubuntu Server 16.04 LTS
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

I install gitea with docker,create a new repository on the website,when i run git push -u origin master
get that error message:

 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'http://192.168.10.130:10080/mr9esx/test.git'

The command of created the docker container:
sudo docker run -d --name=gitea_service --restart always -p 10022:22 -p 10080:3000 -v /mnt/gitea:/data gitea/gitea:latest

This is my app.ini setting:

APP_NAME = Mr9esx's Github
RUN_MODE = prod
RUN_USER = git

[repository]
ROOT = /data/git/repositories

[repository.upload]
TEMP_PATH = /data/gitea/uploads

[server]
APP_DATA_PATH    = /data/gitea
SSH_DOMAIN       = 192.168.10.130
HTTP_PORT        = 10080
ROOT_URL         = http://192.168.10.130:10080/
DISABLE_SSH      = false
SSH_PORT         = 10022
DOMAIN           = 192.168.10.130
LFS_START_SERVER = true
LFS_CONTENT_PATH = /data/gitea/lfs
LFS_JWT_SECRET   = oShOkBDcrn5Vdg-J_4UNQtYpCQEVVoNVWYQOyA-nhHM
OFFLINE_MODE     = true

[database]
PATH     = /data/gitea/gitea.db
DB_TYPE  = sqlite3
HOST     = localhost:3306
NAME     = gitea
USER     = root
PASSWD   = 
SSL_MODE = disable

[session]
PROVIDER_CONFIG = /data/gitea/sessions
PROVIDER        = file

[picture]
AVATAR_UPLOAD_PATH      = /data/gitea/avatars
DISABLE_GRAVATAR        = true
ENABLE_FEDERATED_AVATAR = false

[attachment]
PATH = /data/gitea/attachments

[log]
ROOT_PATH = /data/gitea/log
MODE      = file
LEVEL     = Info

[security]
INSTALL_LOCK   = true
SECRET_KEY     = 31oMSbCLSG
INTERNAL_TOKEN = eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYmYiOjE1MTE5MjMzNDZ9.6wAReQJgEfCpKetJr0A6bO1vi4vWQV_0opb10JdIn6Q

[mailer]
ENABLED = false

[service]
REGISTER_EMAIL_CONFIRM            = false
ENABLE_NOTIFY_MAIL                = false
DISABLE_REGISTRATION              = true
ENABLE_CAPTCHA                    = false
REQUIRE_SIGNIN_VIEW               = true
DEFAULT_KEEP_EMAIL_PRIVATE        = false
DEFAULT_ALLOW_CREATE_ORGANIZATION = true
DEFAULT_ENABLE_TIMETRACKING       = true
NO_REPLY_ADDRESS                  = noreply.example.org

[openid]
ENABLE_OPENID_SIGNIN = true
ENABLE_OPENID_SIGNUP = false

@lunny
Copy link
Member

lunny commented Nov 29, 2017

related with #2270

@Mr9esx
Copy link
Author

Mr9esx commented Nov 29, 2017

fixed!
sudo docker run -d --name=gitea_service --restart always -p 10022:22 -p 10080:3000 -v /mnt/gitea:/data gitea/gitea:latest

to

sudo docker run -d --name=gitea_service --restart always -p 10022:22 -p 3000:3000 -v /mnt/gitea:/data gitea/gitea:latest

@Mr9esx Mr9esx closed this as completed Nov 29, 2017
@BarbosaThaKid727
Copy link

Hi I am having the same issue, I have tried to apply the solution provided here #2270 still having issues.
Its a new install.

@BarbosaThaKid727
Copy link

I'm running Windows Server 2012

@BarbosaThaKid727
Copy link

APP_NAME = <>
RUN_USER = <<RUN_USER>>
RUN_MODE = prod

[oauth2]
JWT_SECRET = [...]

[security]
INTERNAL_TOKEN = [...]
INSTALL_LOCK = true
SECRET_KEY = [...]

[database]
DB_TYPE = postgres
HOST = 127.0.0.1:5432
NAME = gitea
USER = user
PASSWD = [...]
SSL_MODE = disable
CHARSET = utf8
PATH = C:\gitea\data\gitea.db

[repository]
ROOT = C:/gitea/gitea-repositories

[server]
SSH_DOMAIN = localhost
DOMAIN = localhost
HTTP_PORT = 3000
ROOT_URL = http://server-name:3000/
DISABLE_SSH = false
SSH_PORT = 22
LFS_START_SERVER = true
LFS_CONTENT_PATH = C:/gitea/data/lfs
LFS_JWT_SECRET = [...]
OFFLINE_MODE = false
LOCAL_ROOT_URL = http://localhost:3000/

[mailer]
ENABLED = false

@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants