mirror of https://github.com/usememos/memos
feat: add build&push docker image action
* feat: add build&push docker image action * fix file end linepull/8/head
parent
27bd3e80de
commit
247e37d5af
@ -0,0 +1,2 @@
|
|||||||
|
web/node_modules
|
||||||
|
web/yarn.lock
|
@ -0,0 +1,31 @@
|
|||||||
|
name: build-and-push-docker-image
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- "main"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
docker:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Login to Docker Hub
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_NEOSMEMO_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_NEOSMEMO_TOKEN }}
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
id: buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
|
||||||
|
- name: Build and Push
|
||||||
|
id: docker_build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: ./
|
||||||
|
file: ./Dockerfile
|
||||||
|
push: true
|
||||||
|
tags: ${{ secrets.DOCKER_NEOSMEMO_USERNAME }}/memos:latest
|
@ -0,0 +1,6 @@
|
|||||||
|
package config
|
||||||
|
|
||||||
|
var (
|
||||||
|
GITHUB_CLIENTID = "187ba36888f152b06612"
|
||||||
|
GITHUB_SECRET = "10b6fec4146cbb7bdf64016b3cf0905366a35041"
|
||||||
|
)
|
Loading…
Reference in New Issue