Compare commits

...

19 Commits

Author SHA1 Message Date
a624669980
4a77548b23 Modify the publishing process 2021-09-30 16:51:20 +08:00
a624669980
15ccade3d3 Modify the publishing process 2021-09-30 16:42:00 +08:00
a624669980
587fb6fb8a Modify the publishing process 2021-09-30 16:29:32 +08:00
a624669980
5bcb663ac8 Modify the publishing process 2021-09-30 16:26:36 +08:00
a624669980
cbd945536d Modify the publishing process 2021-09-30 16:14:09 +08:00
a624669980
081e9213c2 Modify the publishing process 2021-09-30 16:13:14 +08:00
a624669980
966fae2d4c Modify the publishing process 2021-09-30 16:12:45 +08:00
a624669980
dc4f9ea990 Modify the publishing process 2021-09-30 16:06:56 +08:00
a624669980
05b9c75714 Modify the publishing process 2021-09-30 15:55:02 +08:00
a624669980
4aeeea2325 Modify the publishing process 2021-09-30 15:52:56 +08:00
a624669980
72531cf6c2 Modify the publishing process 2021-09-30 15:45:09 +08:00
a624669980
9ad9be8c61 Modify the publishing process 2021-09-30 15:34:02 +08:00
a624669980
1aa15932a0 Modify the publishing process 2021-09-30 15:24:18 +08:00
a624669980
dbc6a4265a Modify the publishing process 2021-09-30 15:22:05 +08:00
a624669980
edea1f144a Modify the publishing process 2021-09-30 15:10:41 +08:00
a624669980
85c59c03cf Modify the publishing process 2021-09-30 14:52:32 +08:00
a624669980
a1f57bf1d1 Modify the publishing version 2021-09-30 14:45:33 +08:00
a624669980
e6f2c46c28 Modify the publishing process 2021-09-30 14:43:45 +08:00
a624669980
55c6c21aa3 Ignore profile 2021-09-29 19:51:40 +08:00
5 changed files with 132 additions and 72 deletions

View File

@@ -3,10 +3,20 @@
name: Build CasaOS
on:
release:
types:
- created
repository_dispatch:
workflow_dispatch:
inputs:
ssh:
description: 'SSH connection to Actions'
required: false
default: 'false'
#on:
# push:
# branches:
# - 'main'
# tags:
# - 'v*'
env:
REPO_URL: https://github.com/IceWhaleTech/CasaOS.git
REPO_BRANCH: main
@@ -23,80 +33,122 @@ jobs:
- 1.17.1
runs-on: ubuntu-latest
steps:
- name: Get release
id: get_release
uses: bruceadams/get-release@v1.2.3
env:
GITHUB_TOKEN: ${{ github.token }}
- name: Initialization environment
env:
DEBIAN_FRONTEND: noninteractive
# - name: Get release
# id: get_release
# uses: bruceadams/get-release@v1.2.3
# env:
# GITHUB_TOKEN: ${{ github.token }}
- uses: actions/checkout@v2
with:
fetch-depth: 0
submodules: true
# - name: Initialization environment
# env:
# DEBIAN_FRONTEND: noninteractive
# run: |
# sudo timedatectl set-timezone "$TZ"
# sudo mkdir -p /workdir
# sudo chown $USER:$GROUPS /workdir
# - name: Clone source code
# working-directory: /workdir
# run: |
# df -hT $PWD
# git clone $REPO_URL -b $REPO_BRANCH --recursive casa
# ln -sf /workdir/casa $GITHUB_WORKSPACE/casa
# ls
- name: Set enviroment for github-release
run: |
sudo timedatectl set-timezone "$TZ"
sudo mkdir -p /workdir
sudo chown $USER:$GROUPS /workdir
- name: Clone source code
working-directory: /workdir
run: |
df -hT $PWD
git clone $REPO_URL -b $REPO_BRANCH --recursive casa
ln -sf /workdir/casa $GITHUB_WORKSPACE/casa
ls
echo "VERSION=$(cat types/system.go | grep CURRENTVERSION | awk '$2 == "CURRENTVERSION"{print $4}' | sed 's/"//g')" >>$GITHUB_ENV
echo "BODY=$(cat types/system.go | grep BODY | awk -F= '{print $2}' | sed 's/"//g')" >>$GITHUB_ENV
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Build frontend with nodejs and yarn
run: |
cd casa/UI
ls
yarn install
yarn build
- name: Build with xgo
uses: crazy-max/ghaction-xgo@v1
with:
working_dir: /workdir/casa
xgo_version: latest
go_version: ${{ matrix.go_version }}
dest: build
prefix: casa
targets: linux/amd64,linux/arm64
v: true
x: false
race: false
ldflags: -s -w
buildmode: default
# - name: Build frontend with nodejs and yarn
# run: |
# cd casa/UI
# ls
# yarn install
# yarn build
- name: list work
run: pwd
# - name: Build with xgo
# uses: crazy-max/ghaction-xgo@v1
# with:
# xgo_version: latest
# go_version: ${{ matrix.go_version }}
# dest: build
# prefix: casa
# targets: linux/amd64,linux/arm64
# v: true
# x: false
# race: false
# ldflags: -s -w
# buildmode: default
- name: List Files
run: |
ls
cd casa/build
mkdir build
cd build
touch casa-linux-amd64
touch casa-linux-arm64
ls
echo "::set-output name=status::success"
- name: Pack builds
run: |
cd /workdir
wget $PACK_SH_URL
chmod +x $PACK_SH
./$PACK_SH
echo "::set-output name=status::success"
- name: Upload linux-amd64-casaos.tar.gz
id: upload_assets_amd64
uses: shogo82148/actions-upload-release-asset@v1
- name: list work
run: ls
# - name: move
# run: |
# ls
# mv /workdir/casa/upload/linux-amd64-casaos.tar.gz ./linux-amd64-casaos.tar.gz
# mv /workdir/casa/upload/linux-arm64-casaos.tar.gz ./linux-arm64-casaos.tar.gz
- name: Update release
uses: meeDamian/github-release@2.0
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: /workdir/casa/upload/linux-amd64-casaos.tar.gz
- name: Upload linux-arm64-casaos.tar.gz
id: upload_assets_arm64
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: /workdir/casa/upload/linux-arm64-casaos.tar.gz
token: ${{ secrets.GITHUB_TOKEN }}
files: >
linux-amd64-casaos.tar.gz
linux-arm64-casaos.tar.gz
tag: v${{ env.VERSION }}
body: >
${{ env.BODY }}
name: v${{ env.VERSION }}
gzip: false
allow_override: false
prerelease: true
# - name: Upload linux-amd64-casaos.tar.gz
# id: upload_assets_amd64
# uses: shogo82148/actions-upload-release-asset@v1
# with:
# upload_url: ${{ steps.get_release.outputs.upload_url }}
# asset_path: /workdir/casa/upload/linux-amd64-casaos.tar.gz
#
# - name: Upload linux-arm64-casaos.tar.gz
# id: upload_assets_arm64
# uses: shogo82148/actions-upload-release-asset@v1
# with:
# upload_url: ${{ steps.get_release.outputs.upload_url }}
# asset_path: /workdir/casa/upload/linux-arm64-casaos.tar.gz

1
.gitignore vendored
View File

@@ -28,3 +28,4 @@ gen
/out/
/db/
/docs/
/conf/

2
UI

Submodule UI updated: 1f2ebd05fa...c75085250a

View File

@@ -1,7 +1,8 @@
[app]
PAGE_SIZE = 10
RuntimeRootPath = runtime/
LogSavePath = /casaOS/logs/server/
;LogSavePath = /casaOS/logs/server/
LogSavePath = /oasis/logs/server/
LogSaveName = log
LogFileExt = log
; 必须的格式
@@ -9,13 +10,17 @@ DateStrFormat = 20060102
DateTimeFormat = 2006-01-02 15:04:05
TimeFormat = 15:04:05
DateFormat = 2006-01-02
ProjectPath = /casaOS/server
;ProjectPath = /casaOS/server
ProjectPath = /oasis/server
[server]
HttpPort = 8089
RunMode = release
ServerApi = https://api.casaos.zimaboard.com
RunMode = debug
;ServerApi = http://113.52.135.30:8090
;ServerApi = https://casaos.zimaboard.com
;ServerApi = http://192.168.2.167:8090
ServerApi = http://192.168.2.142:8090
[user]
UserName = admin
@@ -42,5 +47,6 @@ SearchSwitch = true
WidgetsSwitch = false
ShortcutsSwitch = true
SearchEngine = baidu
Background = http://google.com
BackgroundType = d
Background = http://baidu.com1
BackgroundType = d

View File

@@ -1,3 +1,4 @@
package types
const CURRENTVERSION = "0.1.2"
const CURRENTVERSION = "0.1.4"
const BODY = "<li> Modify the publishing process</li> <li>Optimized app parameter display</li>"