add actions on push
parent
8d1827609a
commit
d2e7ee007a
|
|
@ -0,0 +1,67 @@
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- ".forgejo/workflows/push/web.yaml"
|
||||||
|
- "./**"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
create-package:
|
||||||
|
runs-on: self-hosted
|
||||||
|
container:
|
||||||
|
image: catthehacker/ubuntu:act-latest
|
||||||
|
# options: "-v "
|
||||||
|
steps:
|
||||||
|
- name: Check out repo
|
||||||
|
- uses: https://code.forgejo.org/actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Set up Docker BuildX
|
||||||
|
uses: docker/setup-buildx-action@v2
|
||||||
|
|
||||||
|
- name: Connect to git2.workstreams.ch Docker registry
|
||||||
|
- uses: https://github.com/docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: git2.workstreams.ch
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Set RELEASE_TAG
|
||||||
|
run: |
|
||||||
|
release_timestamp="$(date +%s)"
|
||||||
|
release_short_sha="$(git rev-parse --short HEAD)"
|
||||||
|
release_tag="$release_timestamp-$release_short_sha"
|
||||||
|
echo "RELEASE_TAG=$release_tag" >> $GITHUB_ENV
|
||||||
|
echo "the release tag will be '$release_tag'"
|
||||||
|
|
||||||
|
- name: Set PRODUCT_VERSION and BUILD_NUMBER
|
||||||
|
run: |
|
||||||
|
export $(grep -v '^#' .env | xargs)
|
||||||
|
echo "PRODUCT_VERSION=$product_version" >> $GITHUB_ENV
|
||||||
|
echo "BUILD_NUMBER=$build_number" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
- name: Docker Build
|
||||||
|
- uses: https://github.com/docker/build-push-action@v4
|
||||||
|
env:
|
||||||
|
ACTIONS_RUNTIME_TOKEN: "" # See https://gitea.com/gitea/act_runner/issues/119
|
||||||
|
with:
|
||||||
|
context: ./
|
||||||
|
build-args: |
|
||||||
|
product_version=${{ env.PRODUCT_VERSION }}
|
||||||
|
build_number=${{ env.BUILD_NUMBER }}
|
||||||
|
file: ./Dockerfile
|
||||||
|
platforms: |
|
||||||
|
linux/amd64
|
||||||
|
push: true
|
||||||
|
tags: |
|
||||||
|
git2.workstreams.ch/workstreams-os/ws-office-dev:${{ env.RELEASE_TAG }}
|
||||||
|
# cache-from: type=local,src=/tmp/.buildx-cache
|
||||||
|
# cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max
|
||||||
|
|
||||||
|
# - # Temp fix
|
||||||
|
# # https://github.com/docker/build-push-action/issues/252
|
||||||
|
# # https://github.com/moby/buildkit/issues/1896
|
||||||
|
# name: Move cache
|
||||||
|
# run: |
|
||||||
|
# rm -rf /tmp/.buildx-cache
|
||||||
|
# mv /tmp/.buildx-cache-new /tmp/.buildx-cache
|
||||||
|
|
@ -84,3 +84,5 @@ COPY --from=build-stage --chown=ds:ds /build/web-apps/deploy/web-apps/apps/docum
|
||||||
COPY --from=build-stage --chown=ds:ds /build/web-apps/deploy/web-apps/apps/presentationeditor/mobile ${oo_root}/web-apps/apps/presentationeditor/mobile
|
COPY --from=build-stage --chown=ds:ds /build/web-apps/deploy/web-apps/apps/presentationeditor/mobile ${oo_root}/web-apps/apps/presentationeditor/mobile
|
||||||
COPY --from=build-stage --chown=ds:ds /build/web-apps/deploy/web-apps/apps/spreadsheeteditor/mobile ${oo_root}/web-apps/apps/spreadsheeteditor/mobile
|
COPY --from=build-stage --chown=ds:ds /build/web-apps/deploy/web-apps/apps/spreadsheeteditor/mobile ${oo_root}/web-apps/apps/spreadsheeteditor/mobile
|
||||||
|
|
||||||
|
COPY local-production-linux.json /etc/onlyoffice/documentserver/local-production-linux.json
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,44 @@
|
||||||
|
{
|
||||||
|
"services": {
|
||||||
|
"CoAuthoring": {
|
||||||
|
"server": {
|
||||||
|
"savetimeoutdelay": 15000
|
||||||
|
},
|
||||||
|
"expire": {
|
||||||
|
"sessionidle": "1h",
|
||||||
|
"sessionabsolute": "1d"
|
||||||
|
},
|
||||||
|
"autoAssembly": {
|
||||||
|
"enable": true,
|
||||||
|
"interval": "1m"
|
||||||
|
},
|
||||||
|
"callbackBackoffOptions": {
|
||||||
|
"retries": 10,
|
||||||
|
"timeout": {
|
||||||
|
"factor": 2,
|
||||||
|
"minTimeout": 5000,
|
||||||
|
"maxTimeout": 86400000,
|
||||||
|
"randomize": false
|
||||||
|
},
|
||||||
|
"httpStatus": "404,429,500-599"
|
||||||
|
},
|
||||||
|
"token": {
|
||||||
|
"enable": {
|
||||||
|
"request": {
|
||||||
|
"inbox": false,
|
||||||
|
"outbox": false
|
||||||
|
},
|
||||||
|
"browser": false
|
||||||
|
},
|
||||||
|
"inbox": {
|
||||||
|
"header": "Authorization",
|
||||||
|
"inBody": false
|
||||||
|
},
|
||||||
|
"outbox": {
|
||||||
|
"header": "Authorization",
|
||||||
|
"inBody": false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue