28 Commits (forgejo)

Author SHA1 Message Date
Loïc Dachary 95859da3b4
[BRANDING] symlink gitea to forgejo in docker containers
(cherry picked from commit 9c06a318b867ea8c60dd194ca393bac3b718b07b)
1 year ago
Loïc Dachary 8dff3cc2d1
[CI] implementation: forgejo container images
(cherry picked from commit dd1971d4e60f37fb76daeb6cef8b1defcc957a34)
(cherry picked from commit 3981dbaf8c0dd74b0e82a7afc36809998ac775a2)
1 year ago
zeripath 43405c35f0
Add Bash and Zsh completion scripts (#22646)
This PR adds contrib scripts for bash and zsh completion.

Simply call:

```bash
source contrib/autocompletion/bash_autocomplete
```

or for Zsh:

```bash
source contrib/autocompletion/zsh_autocomplete
```

Signed-off-by: Andrew Thornton <art27@cantab.net>

---------

Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: a1012112796 <1012112796@qq.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
1 year ago
techknowlogick cfb1cb1168
update to build with go1.20 (#22732)
as title

---------

Co-authored-by: Lauris BH <lauris@nix.lv>
1 year ago
Michael Kriese 84d2a820e5
Add dumb-init to rootless docker (#21775)
Add dumb-init as process reaper to the rootless image to reap defunct git processes.
1 year ago
flynnnnnnnnnn 350bc83d00
Update to Alpine 3.17 (#21904)
This pull request is for updating the base docker images to build with
the latest version of Alpine.
1 year ago
techknowlogick be824890e4
Switch to building with go1.19 (#20695) 2 years ago
luzpaz d29d6d1991
Fix various typos (#20338)
* Fix various typos

Found via `codespell -q 3 -S ./options/locale,./options/license,./public/vendor -L actived,allways,attachements,ba,befores,commiter,pullrequest,pullrequests,readby,splitted,te,unknwon`

Co-authored-by: zeripath <art27@cantab.net>
2 years ago
techknowlogick 0cbec3cd37
alpine 3.16 (#19797)
Co-authored-by: 6543 <6543@obermui.de>
2 years ago
techknowlogick ed1d95c55d
use go1.18 to build gitea (#19099)
* use go1.18 to build gitea& update min go version to 1.17

* bump in a few more places

* add a few simple tests for isipprivate

* update go.mod

* update URL to https://go.dev/dl/

* golangci-lint

* attempt golangci-lint workaround

* change version

* bump fumpt version

* skip strings.title test

* go mod tidy

* update tests as some aren't private??

* update tests
2 years ago
Grzegorz Alibożek 4563148a61
Upgrade Alpine from 3.13 to 3.15 (#18050)
* Upgrade alpine to 3.15

* Add executability test to entrypoint for too old dockers

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Update docker/rootless/usr/local/bin/docker-entrypoint.sh

Co-authored-by: zeripath <art27@cantab.net>
2 years ago
techknowlogick d8ae769dda
update docker image to latest go version (#18048) 2 years ago
zeripath 7d0629adf8
Use shadowing script for docker (#17846)
Too many docker users are caught out by the default location for the
app.ini file being environment dependent so that when they docker exec
into the container the gitea commands do not work properly and require
additional -c arguments to correctly pick up the configuration.

This PR simply shadows the gitea binary using variants of the FHS
compatible script to make the command gitea have the default locations
by default.

Fix #14468
Reference #17497
Reference #12082
Reference #8941
... amongst others ...
Replace #17501

Signed-off-by: Andrew Thornton <art27@cantab.net>
2 years ago
wxiaoguang 6e2c64f27a
Fix docker rootless build (#17441) 3 years ago
zeripath 0277603878
chmod executables when copying to the docker (#17423)
Run chmod on the executables and the entrypoint when copying them to the
docker in dockerfile.

Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Norwin <noerw@users.noreply.github.com>
Co-authored-by: delvh <dev.lh@web.de>
3 years ago
techknowlogick 274aeb3a9e
build with go1.17 (#16707)
Co-authored-by: Lauris BH <lauris@nix.lv>
3 years ago
techknowlogick 7b31aae414
revert to use alpine 3.13 (#16451)
Co-authored-by: zeripath <art27@cantab.net>
3 years ago
Jonathan Hult 615444dcbd
Fix #16387 - rootless Docker user (#16388)
Move comment to top of USER instruction
3 years ago
Tobias Florek 5e819ee1de
specify user in rootless container numerically (#16361)
* specify user in rootless container numerically

With kubernetes' PodSecurityPolicy set to runAsNonRoot it will not allow starting the container.  The error message is
```
Error: container has runAsNonRoot and image has non-numeric user (git), cannot verify user is non-root
```
The `USER` directive has to be numerical for that to work.

* mention the name of the uid/gid

Co-authored-by: 6543 <6543@obermui.de>
3 years ago
techknowlogick 061a8e7bb9
Alpine 3.14 released (#16170)
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: zeripath <art27@cantab.net>
3 years ago
Steven 683cfe39ef
Change default TMPDIR path in rootless containers (#16077)
Signed-off-by: Steven Kriegler <61625851+justusbunsi@users.noreply.github.com>
3 years ago
Steven d6d2444f2a
Add curl to rootless docker image (#15908)
Signed-off-by: JustusBunsi <61625851+justusbunsi@users.noreply.github.com>

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
3 years ago
Martin Michaelis d576126286
Remove random password in Dockerfiles (#15362)
* Remove random password of git user in dockerfile

* Disable git user account in rootless dockerfile
3 years ago
techknowlogick 47f6a4ec3f
go1.16 (#14783) 3 years ago
Kyle D 61f347e349
Add environment-to-ini to docker image (#14762)
* Add environment-to-app.ini routine

* Call environment-to-ini in docker setup scripts

* Automatically convert section vars to lower case to match documentation

* Remove git patch instructions

* Add env variable documentation to Install Docker
3 years ago
techknowlogick b708968694
upgrade to alpine 3.13 (#14343) 3 years ago
Lauris BH 8c2b5feeae
When building rootless docker image move chown&chmod to build stage (#13578)
* When building rootless docker image move chown&chmod to build stage

Fixes #13577

* Fix command newlines

* Move chown to COPY command

* Seems to be working also without chmod

Co-authored-by: techknowlogick <techknowlogick@gitea.io>
4 years ago
Antoine GIRARD fe458ce877
docker: rootless image (#10154)
* docker: rootless image

* improve docs + remove check for write perm on custom

* add more info on ssh passtrough

* Add comment for internal ssh server in container config
4 years ago