mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-01 12:22:11 +00:00
Update Dockerfile & build script and add /etc/nsswitch.conf:
- Add nsswitch.conf to configure LibC Name Service inside the container - Change my email in the Dockerfile - Update build script to install software as a `build-deps` virtual package so that adding a package to it will be automatically removed at the end of the build script
This commit is contained in:
parent
38efa72146
commit
9032bd097b
4 changed files with 26 additions and 4 deletions
|
@ -7,7 +7,7 @@ export GOPATH=/tmp/go
|
|||
export PATH=${PATH}:${GOPATH}/bin
|
||||
|
||||
# Install build deps
|
||||
apk -U --no-progress add linux-pam-dev go@community gcc musl-dev
|
||||
apk -U --no-progress add --virtual build-deps linux-pam-dev go@community gcc musl-dev
|
||||
|
||||
# Init go environment to build Gogs
|
||||
mkdir -p ${GOPATH}/src/github.com/gogits/
|
||||
|
@ -20,7 +20,7 @@ go build -tags "sqlite cert pam"
|
|||
rm -r $GOPATH
|
||||
|
||||
# Remove build deps
|
||||
apk --no-progress del linux-pam-dev go gcc musl-dev
|
||||
apk --no-progress del build-deps
|
||||
|
||||
# Create git user for Gogs
|
||||
adduser -H -D -g 'Gogs Git User' git -h /data/git -s /bin/bash && passwd -u git
|
||||
|
|
16
docker/nsswitch.conf
Normal file
16
docker/nsswitch.conf
Normal file
|
@ -0,0 +1,16 @@
|
|||
# /etc/nsswitch.conf
|
||||
|
||||
passwd: compat
|
||||
group: compat
|
||||
shadow: compat
|
||||
|
||||
hosts: files dns
|
||||
networks: files
|
||||
|
||||
protocols: db files
|
||||
services: db files
|
||||
ethers: db files
|
||||
rpc: db files
|
||||
|
||||
netgroup: nis
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue