Skip to content

Commit

Permalink
Merge branch 'master' into beta
Browse files Browse the repository at this point in the history
  • Loading branch information
chenzhipei committed Mar 31, 2024
2 parents fa07dfe + 4fca36c commit d4c96d3
Show file tree
Hide file tree
Showing 63 changed files with 6,309 additions and 1,228 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/deploy-github.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Deploy Github

on:
push:
tags: # Deploy tag (e.g. v1.0) to production
- 'v**'

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Install dependencies
run: yarn install

- name: Build Docusaurus site
run: yarn build
env:
SITE_URL: https://www.steedos.org
SITE_TITLE: Steedos

- name: Deploy to steedos.github.io
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.GIT_DEPLOY_KEY }}
external_repository: steedos/steedos.github.io
publish_branch: gh-pages # default: gh-pages
publish_dir: ./build

8 changes: 5 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ jobs:
uses: actions/checkout@v2

- name: Install dependencies
run: npm install
run: yarn install

- name: Build Docusaurus site
run: npm run build
run: yarn build

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
Expand All @@ -36,4 +36,6 @@ jobs:

- name: Invalidate CloudFront distribution
run: |
aws cloudfront create-invalidation --distribution-id E3PZXWVY8YMW6P --paths "/*"
aws cloudfront create-invalidation --distribution-id E3PZXWVY8YMW6P --paths "/*"
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,14 @@ yarn build:openapi

This command generates static content into the `build` directory and can be served using any static contents hosting service.

### Deploy to Github

```
export GIT_USER=hotlong
export GIT_PASS=
export DEPLOYMENT_BRANCH=master
yarn deploy
```

### Generate PDF

Expand Down
59 changes: 13 additions & 46 deletions docs/deploy/deploy-docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,52 +34,17 @@ version: "3.9"
services:

steedos:
image: steedos/steedos-community:2.5
image: steedos/steedos-community:latest
ports:
- "80:80"
- "80:80" # Steedos
- "27017:27017" # MongoDB
- "9001:9001" # Supervisor
- "6379:6379" # Redis
environment:
- ROOT_URL=http://127.0.0.1
- PORT=80
- MONGO_URL=mongodb://mongodb:27017/steedos
- MONGO_OPLOG_URL=mongodb://mongodb:27017/local
- TRANSPORTER=redis://redis:6379
- CACHER=redis://redis:6379/1
- STEEDOS_STORAGE_DIR=/steedos-storage
- NPM_REGISTRY_URL=https://registry.npmmirror.com
volumes:
- "steedos-storage:/steedos-storage"
depends_on:
redis:
condition: service_started
mongodb:
condition: service_healthy

redis:
image: redis:6.2.10
command: "redis-server --save \"\" --appendonly no --loglevel warning"
ports:
- "6379:6379"

mongodb:
image: mongo:4.4
ports:
- 27017:27017
command: "--bind_ip_all --replSet steedos --logpath /var/log/mongodb/mongod.log"
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongo --quiet | grep 1
interval: 10s
timeout: 10s
retries: 5
volumes:
- 'steedos-mongo-data:/data/db'

mongodb-init:
image: mongo:4.4
restart: "no"
depends_on:
mongodb:
condition: service_healthy
command: >
mongo --host mongodb:27017 --eval "rs.initiate({ _id: 'steedos', members: [{_id: 0, host: 'mongodb:27017'}]})"
- "./steedos-storage:/steedos-storage"

```

Expand All @@ -96,15 +61,17 @@ services:
image: steedos/steedos-enterprise:latest
container_name: steedos-enterprise
ports:
- "80:80"
- "443:443"
- "9001:9001"
- "80:80" # Steedos
- "27017:27017" # MongoDB
- "9001:9001" # Supervisor
- "6379:6379" # Redis
environment:
- ROOT_URL=http://127.0.0.1
- NPM_REGISTRY_URL=https://registry.npmmirror.com
- STEEDOS_LICENSE=trial
tty: true
volumes:
- "./storage:/steedos-storage"
- "./steedos-storage:/steedos-storage"
```
</TabItem>
Expand Down
44 changes: 32 additions & 12 deletions docs/deploy/intranet.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,40 +47,60 @@ Docker version 24.0.7, build afdd53b

## Installing Steedos

On your intranet server, create a folder named `steedos` for deployment and data storage. Download on the connected Linux server:
1. Run the following cURL command to download the `docker-compose.yml` file:
On your intranet server, create a folder named `steedos` for deployment and data storage.

1. Create `docker-compose.yml` file:

```yml
version: "3.9"

services:

steedos:
image: steedos/steedos-community:2.6
ports:
- "5000:5000" # Steedos
- "27017:27017" # MongoDB
- "9001:9001" # Supervisor
- "6379:6379" # Redis
env_file:
- .env
volumes:
- "./steedos-storage:/steedos-storage"
```
2. Create `.env` file:

```shell
curl -L https://raw.githubusercontent.com/steedos/steedos-platform/master/deploy/docker/docker-compose.yml -o $PWD/docker-compose.yml
PORT=80
ROOT_URL=http://serverip
```

Upload the downloaded `docker-compose.yml` file to the `steedos` folder on the intranet server.

2. View the `docker-compose.yml` file and download the relevant images.
3. View the `docker-compose.yml` file and download the relevant images.

```shell
docker pull steedos/steedos-enterprise:2.5
docker pull steedos/steedos-community:2.6
docker pull redis:6.2.10
docker pull mongo:4.4
```

3. Save the downloaded images as rar format files and upload them to the tmp directory of the intranet server.
4. Save the downloaded images as rar format files and upload them to the tmp directory of the intranet server.

```shell
docker save -o steedos-enterprise.rar steedos/steedos-enterprise:2.5
docker save -o steedos-community.rar steedos/steedos-community:2.6
docker save -o redis.rar redis:6.2.10
docker save -o mongo.rar mongo:4.4
```

4. Navigate to the tmp directory on the intranet server and sequentially load the images.
5. Navigate to the tmp directory on the intranet server and sequentially load the images.

```shell
docker load < steedos-enterprise.rar
docker load < steedos-community.rar
docker load < redis.rar
docker load < mongo.rar
```

5. Navigate to the `steedos` directory on the intranet server and use the following command to start the Docker containers. If you don't have permission to run `docker compose`, you might need to use `sudo`.
6. Navigate to the `steedos` directory on the intranet server and use the following command to start the Docker containers. If you don't have permission to run `docker compose`, you might need to use `sudo`.

```shell
docker compose up -d
Expand Down
3 changes: 3 additions & 0 deletions docs/deploy/steedos-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,9 @@ STEEDOS_CRON_SMSQUEUE_INTERVAL=1000

# Polling interval for the object webhooks queue, in milliseconds.
STEEDOS_CRON_OBJECTWEBHOOKSQUEUE_INTERVAL=10000

# Polling interval of the object & workflow synchronization queue, in milliseconds.
STEEDOS_CRON_INSTANCERECORDQUEUE_INTERVAL=10000
```

## Developer Options
Expand Down
Loading

0 comments on commit d4c96d3

Please sign in to comment.