mirror of
https://github.com/paul-nameless/tg
synced 2024-11-21 19:33:09 +00:00
Build docker image in CI (#221)
* Build docker image in CI * Build docker image on any branch temporarely * Update github actions * Update github actions * Update github actions * Update github actions * Update github actions * Update readme * Update github actions
This commit is contained in:
parent
e473ae7d47
commit
da1f1d3514
3 changed files with 23 additions and 3 deletions
13
.github/workflows/main.yml
vendored
13
.github/workflows/main.yml
vendored
|
@ -31,3 +31,16 @@ jobs:
|
|||
- name: Check formatting and run linters
|
||||
run: |
|
||||
sh check.sh
|
||||
|
||||
- name: build and deploy master image to ghcr.io
|
||||
# if: ${{ github.ref == 'refs/heads/master' }}
|
||||
env:
|
||||
PKG_TOKEN: ${{ secrets.PKG_TOKEN }}
|
||||
USERNAME: ${{ github.actor }}
|
||||
run: |
|
||||
git_hash=$(git rev-parse --short "$GITHUB_SHA")
|
||||
git_branch="$(echo ${GITHUB_REF} | cut -d'/' -f3)"
|
||||
echo ${PKG_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin
|
||||
docker build -t ghcr.io/${USERNAME}/tg:${git_branch}-${git_hash} -t ghcr.io/${USERNAME}/tg:latest .
|
||||
docker push ghcr.io/${USERNAME}/tg:${git_branch}-${git_hash}
|
||||
docker push ghcr.io/${USERNAME}/tg:latest
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
FROM python:3.8.3-slim-buster
|
||||
FROM python:3.9.4-slim-buster
|
||||
|
||||
RUN pip install tg
|
||||
|
||||
|
|
11
readme.md
11
readme.md
|
@ -61,6 +61,13 @@ pip3 install tg
|
|||
tg
|
||||
```
|
||||
|
||||
### Homebrew
|
||||
|
||||
```sh
|
||||
brew tap paul-nameless/homebrew-repo
|
||||
brew install tg
|
||||
```
|
||||
|
||||
### From sources
|
||||
|
||||
This option is recommended for development:
|
||||
|
@ -75,10 +82,10 @@ tg
|
|||
|
||||
### Using Docker
|
||||
|
||||
> Please note that voice recordings and notifications won't work when using Docker.
|
||||
> Note that voice recordings and notifications won't work when using Docker.
|
||||
|
||||
```sh
|
||||
docker run -it --rm tg
|
||||
docker run -it --rm ghcr.io/paul-nameless/tg
|
||||
```
|
||||
|
||||
### From the AUR
|
||||
|
|
Loading…
Reference in a new issue