Add build CI and update README.md
Signed-off-by: AKP <tom@tdpain.net>
This commit is contained in:
parent
1d325e15d3
commit
7685f77a88
2 changed files with 38 additions and 50 deletions
36
.github/workflows/build.yml
vendored
Normal file
36
.github/workflows/build.yml
vendored
Normal file
|
@ -0,0 +1,36 @@
|
|||
name: Docker Image CI
|
||||
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
|
||||
env:
|
||||
IMAGE_NAME: "ghcr.io/codemicro/bookstack"
|
||||
|
||||
jobs:
|
||||
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Get tag version
|
||||
id: get_version
|
||||
run: echo "::set-output name=VERSION::$(echo ${GITHUB_REF/refs\/tags\//} | sed "s/^v//")"
|
||||
|
||||
- name: Make image tags
|
||||
id: make_tags
|
||||
run: |
|
||||
echo "::set-output name=LATEST::$IMAGE_NAME:latest"
|
||||
echo "::set-output name=VERSIONED::$IMAGE_NAME:${{ steps.get_version.outputs.VERSION }}"
|
||||
|
||||
- name: Build Docker image
|
||||
run: docker build . --file Dockerfile --tag ${{ steps.make_tags.outputs.LATEST }} --tag ${{ steps.make_tags.outputs.VERSIONED }}
|
||||
|
||||
- name: Login to ghcr.io
|
||||
run: echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io --username codemicro --password-stdin
|
||||
|
||||
- name: Push image
|
||||
run: docker push --all-tags $IMAGE_NAME
|
52
README.md
52
README.md
|
@ -1,59 +1,11 @@
|
|||
## Docker Image For [BookStack](https://github.com/ssddanbrown/BookStack)
|
||||
|
||||
[](https://travis-ci.org/solidnerd/docker-bookstack) [](https://microbadger.com/images/solidnerd/bookstack "Get your own image badge on microbadger.com") [](https://microbadger.com/images/solidnerd/bookstack "Get your own commit badge on microbadger.com") [](https://microbadger.com/images/solidnerd/bookstack "Get your own version badge on microbadger.com") [](https://microbadger.com/images/solidnerd/bookstack "Get your own license badge on microbadger.com")
|
||||
|
||||
## Current Version: [22.04.02](https://github.com/SolidNerd/docker-bookstack/blob/master/Dockerfile)
|
||||
|
||||
### Changes
|
||||
|
||||
In 0.28.0 we changed the container http port from 80 to 8080 to allow root privileges to be dropped
|
||||
In 0.12.2 we removed `DB_PORT` . You can now specify the port via `DB_HOST` like `DB_HOST=mysql:3306`
|
||||
|
||||
### Quickstart
|
||||
|
||||
With Docker Compose is a Quickstart very easy. Run the following command:
|
||||
|
||||
```
|
||||
docker-compose up
|
||||
```
|
||||
|
||||
and after that open your Browser and go to [http://localhost:8080](http://localhost:8080) . You can login with username 'admin@admin.com' and password 'password'.
|
||||
|
||||
### Issues
|
||||
|
||||
If you have any issues feel free to create an [issue on GitHub](https://github.com/solidnerd/docker-bookstack/issues).
|
||||
|
||||
|
||||
### How to use the Image without Docker compose
|
||||
|
||||
Note that if you want to use LDAP, `$` has to be escape like `\$`, i.e. `-e "LDAP_USER_FILTER"="(&(uid=\${user}))"`
|
||||
|
||||
Networking changed in Docker v1.9, so you need to do one of the following steps.
|
||||
|
||||
#### Docker < v1.9
|
||||
|
||||
1. MySQL Container:
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
-p 3306:3306 \
|
||||
-e MYSQL_ROOT_PASSWORD=secret \
|
||||
-e MYSQL_DATABASE=bookstack \
|
||||
-e MYSQL_USER=bookstack \
|
||||
-e MYSQL_PASSWORD=secret \
|
||||
--name bookstack_db \
|
||||
mysql:5.7.21
|
||||
```
|
||||
2. BookStack Container:
|
||||
|
||||
```bash
|
||||
docker run -d --link bookstack_db_:mysql \
|
||||
-p 8080:8080 \
|
||||
--name bookstack_22.04.02 \
|
||||
solidnerd/bookstack:22.04.02
|
||||
```
|
||||
|
||||
#### Docker 1.9+
|
||||
*(For Docker 1.9+)*
|
||||
|
||||
1. Create a shared network:
|
||||
|
||||
|
@ -104,4 +56,4 @@ After these steps you can visit [http://localhost:8080](http://localhost:8080) .
|
|||
|
||||
### Inspiration
|
||||
|
||||
This is a fork of [Kilhog/docker-bookstack](https://github.com/Kilhog/docker-bookstack). Kilhog did the intial work, but I want to go in a different direction.
|
||||
This is a fork of [solidnerd/docker-bookstack](https://github.com/solidnerd/docker-bookstack), which is in turn a fork of [Kilhog/docker-bookstack](https://github.com/Kilhog/docker-bookstack). Kilhog did the intial work, solidnerd wanted to go in a different direction and I wanted an up-to-date version of the image.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue