Merge branch 'main' into docs/add-stirling-pdf-tutorial
@@ -317,7 +317,7 @@ spec:
|
||||
chown -R 1000:1000 /uploadstemp && \
|
||||
chown -R 1000:1000 /appdata
|
||||
- name: olares-app-init
|
||||
image: beclab/system-frontend:v1.7.1
|
||||
image: beclab/system-frontend:v1.7.4
|
||||
imagePullPolicy: IfNotPresent
|
||||
command:
|
||||
- /bin/sh
|
||||
@@ -439,7 +439,7 @@ spec:
|
||||
- name: NATS_SUBJECT_VAULT
|
||||
value: os.vault.{{ .Values.bfl.username}}
|
||||
- name: user-service
|
||||
image: beclab/user-service:v0.0.81
|
||||
image: beclab/user-service:v0.0.82
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 3000
|
||||
|
||||
@@ -36,6 +36,7 @@ import (
|
||||
"github.com/beclab/Olares/cli/pkg/k3s/templates"
|
||||
"github.com/beclab/Olares/cli/pkg/manifest"
|
||||
"github.com/beclab/Olares/cli/pkg/registry"
|
||||
"github.com/beclab/Olares/cli/pkg/storage"
|
||||
)
|
||||
|
||||
type InstallContainerModule struct {
|
||||
@@ -470,6 +471,18 @@ func (j *JoinNodesModule) Init() {
|
||||
Parallel: true,
|
||||
}
|
||||
|
||||
createSharedLibDirForWorker := &task.RemoteTask{
|
||||
Name: "CreateSharedLibDir(k3s)",
|
||||
Desc: "Create shared lib directory on worker",
|
||||
Hosts: j.Runtime.GetHostsByRole(common.Worker),
|
||||
Prepare: &prepare.PrepareCollection{
|
||||
&kubernetes.NodeInCluster{Not: true},
|
||||
new(common.OnlyWorker),
|
||||
},
|
||||
Action: new(storage.CreateSharedLibDir),
|
||||
Parallel: true,
|
||||
}
|
||||
|
||||
enableK3s := &task.RemoteTask{
|
||||
Name: "EnableK3sService",
|
||||
Desc: "Enable k3s service",
|
||||
@@ -536,6 +549,7 @@ func (j *JoinNodesModule) Init() {
|
||||
k3sService,
|
||||
k3sEnv,
|
||||
k3sRegistryConfig,
|
||||
createSharedLibDirForWorker,
|
||||
enableK3s,
|
||||
copyKubeConfigForMaster,
|
||||
syncKubeConfigToWorker,
|
||||
|
||||
@@ -397,53 +397,23 @@ type CopyK3sKubeConfig struct {
|
||||
}
|
||||
|
||||
func (c *CopyK3sKubeConfig) Execute(runtime connector.Runtime) error {
|
||||
createConfigDirCmd := "mkdir -p /root/.kube && mkdir -p $HOME/.kube"
|
||||
getKubeConfigCmd := "cp -f /etc/rancher/k3s/k3s.yaml /root/.kube/config"
|
||||
chmodKubeConfigCmd := "chmod 0600 /root/.kube/config"
|
||||
targetHome, targetUID, targetGID, err := utils.ResolveSudoUserHomeAndIDs(runtime)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
cmd := strings.Join([]string{createConfigDirCmd, getKubeConfigCmd, chmodKubeConfigCmd}, " && ")
|
||||
if _, err := runtime.GetRunner().SudoCmd(cmd, false, false); err != nil {
|
||||
cmds := []string{
|
||||
"mkdir -p /root/.kube",
|
||||
"cp -f /etc/rancher/k3s/k3s.yaml /root/.kube/config",
|
||||
"chmod 0600 /root/.kube/config",
|
||||
fmt.Sprintf("mkdir -p %s", filepath.Join(targetHome, ".kube")),
|
||||
fmt.Sprintf("cp -f /etc/rancher/k3s/k3s.yaml %s", filepath.Join(targetHome, ".kube", "config")),
|
||||
fmt.Sprintf("chmod 0600 %s", filepath.Join(targetHome, ".kube", "config")),
|
||||
fmt.Sprintf("chown -R %s:%s %s", targetUID, targetGID, filepath.Join(targetHome, ".kube")),
|
||||
}
|
||||
if _, err := runtime.GetRunner().SudoCmd(strings.Join(cmds, " && "), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "copy k3s kube config failed")
|
||||
}
|
||||
|
||||
userMkdir := "mkdir -p $HOME/.kube"
|
||||
if _, err := runtime.GetRunner().Cmd(userMkdir, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user mkdir $HOME/.kube failed")
|
||||
}
|
||||
|
||||
userCopyKubeConfig := "cp -f /etc/rancher/k3s/k3s.yaml $HOME/.kube/config"
|
||||
if _, err := runtime.GetRunner().SudoCmd(userCopyKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user copy /etc/rancher/k3s/k3s.yaml to $HOME/.kube/config failed")
|
||||
}
|
||||
|
||||
if _, err := runtime.GetRunner().SudoCmd("chmod 0600 $HOME/.kube/config", false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chmod k3s $HOME/.kube/config 0600 failed")
|
||||
}
|
||||
|
||||
// userId, err := runtime.GetRunner().Cmd("echo $(id -u)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
// }
|
||||
|
||||
// userGroupId, err := runtime.GetRunner().Cmd("echo $(id -g)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
// }
|
||||
|
||||
userId, err := runtime.GetRunner().Cmd("echo $SUDO_UID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
}
|
||||
|
||||
userGroupId, err := runtime.GetRunner().Cmd("echo $SUDO_GID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
}
|
||||
|
||||
chownKubeConfig := fmt.Sprintf("chown -R %s:%s $HOME/.kube", userId, userGroupId)
|
||||
if _, err := runtime.GetRunner().SudoCmd(chownKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chown user kube config failed")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -493,59 +463,29 @@ func (s *SyncKubeConfigToWorker) Execute(runtime connector.Runtime) error {
|
||||
if v, ok := s.PipelineCache.Get(common.ClusterStatus); ok {
|
||||
cluster := v.(*K3sStatus)
|
||||
|
||||
createConfigDirCmd := "mkdir -p /root/.kube"
|
||||
if _, err := runtime.GetRunner().SudoCmd(createConfigDirCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "create .kube dir failed")
|
||||
}
|
||||
|
||||
oldServer := "server: https://127.0.0.1:6443"
|
||||
newServer := fmt.Sprintf("server: https://%s:%d",
|
||||
s.KubeConf.Cluster.ControlPlaneEndpoint.Domain,
|
||||
s.KubeConf.Cluster.ControlPlaneEndpoint.Port)
|
||||
newKubeConfig := strings.Replace(cluster.KubeConfig, oldServer, newServer, -1)
|
||||
|
||||
syncKubeConfigForRootCmd := fmt.Sprintf("echo '%s' > %s", newKubeConfig, "/root/.kube/config")
|
||||
if _, err := runtime.GetRunner().SudoCmd(syncKubeConfigForRootCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config for root failed")
|
||||
}
|
||||
|
||||
if _, err := runtime.GetRunner().SudoCmd("chmod 0600 /root/.kube/config", false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chmod k3s $HOME/.kube/config failed")
|
||||
}
|
||||
|
||||
userConfigDirCmd := "mkdir -p $HOME/.kube"
|
||||
if _, err := runtime.GetRunner().Cmd(userConfigDirCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user mkdir $HOME/.kube failed")
|
||||
}
|
||||
|
||||
syncKubeConfigForUserCmd := fmt.Sprintf("echo '%s' > %s", newKubeConfig, "$HOME/.kube/config")
|
||||
if _, err := runtime.GetRunner().Cmd(syncKubeConfigForUserCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config for normal user failed")
|
||||
}
|
||||
|
||||
// userId, err := runtime.GetRunner().Cmd("echo $(id -u)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
// }
|
||||
|
||||
// userGroupId, err := runtime.GetRunner().Cmd("echo $(id -g)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
// }
|
||||
|
||||
userId, err := runtime.GetRunner().Cmd("echo $SUDO_UID", false, false)
|
||||
targetHome, targetUID, targetGID, err := utils.ResolveSudoUserHomeAndIDs(runtime)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
return err
|
||||
}
|
||||
targetKubeConfigPath := filepath.Join(targetHome, ".kube", "config")
|
||||
|
||||
userGroupId, err := runtime.GetRunner().Cmd("echo $SUDO_GID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
cmds := []string{
|
||||
"mkdir -p /root/.kube",
|
||||
fmt.Sprintf("echo '%s' > %s", newKubeConfig, "/root/.kube/config"),
|
||||
"chmod 0600 /root/.kube/config",
|
||||
fmt.Sprintf("mkdir -p %s", filepath.Join(targetHome, ".kube")),
|
||||
fmt.Sprintf("echo '%s' > %s", newKubeConfig, targetKubeConfigPath),
|
||||
fmt.Sprintf("chmod 0600 %s", targetKubeConfigPath),
|
||||
fmt.Sprintf("chown -R %s:%s %s", targetUID, targetGID, filepath.Join(targetHome, ".kube")),
|
||||
}
|
||||
|
||||
chownKubeConfig := fmt.Sprintf("chown -R %s:%s -R $HOME/.kube", userId, userGroupId)
|
||||
if _, err := runtime.GetRunner().SudoCmd(chownKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chown user kube config failed")
|
||||
if _, err := runtime.GetRunner().SudoCmd(strings.Join(cmds, " && "), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config failed")
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
@@ -23,6 +23,7 @@ import (
|
||||
"github.com/beclab/Olares/cli/pkg/core/prepare"
|
||||
"github.com/beclab/Olares/cli/pkg/core/task"
|
||||
"github.com/beclab/Olares/cli/pkg/manifest"
|
||||
"github.com/beclab/Olares/cli/pkg/storage"
|
||||
)
|
||||
|
||||
type StatusModule struct {
|
||||
@@ -243,6 +244,18 @@ func (j *JoinNodesModule) Init() {
|
||||
Retry: 5,
|
||||
}
|
||||
|
||||
createSharedLibDirForWorker := &task.RemoteTask{
|
||||
Name: "CreateSharedLibDir(k8s)",
|
||||
Desc: "Create shared lib directory on worker",
|
||||
Hosts: j.Runtime.GetHostsByRole(common.Worker),
|
||||
Prepare: &prepare.PrepareCollection{
|
||||
&NodeInCluster{Not: true},
|
||||
new(common.OnlyWorker),
|
||||
},
|
||||
Action: new(storage.CreateSharedLibDir),
|
||||
Parallel: true,
|
||||
}
|
||||
|
||||
joinWorkerNode := &task.RemoteTask{
|
||||
Name: "JoinWorkerNode(k8s)",
|
||||
Desc: "Join worker node",
|
||||
@@ -323,6 +336,7 @@ func (j *JoinNodesModule) Init() {
|
||||
j.Tasks = []task.Interface{
|
||||
generateKubeadmConfig,
|
||||
joinMasterNode,
|
||||
createSharedLibDirForWorker,
|
||||
joinWorkerNode,
|
||||
copyKubeConfig,
|
||||
removeMasterTaint,
|
||||
|
||||
@@ -417,51 +417,23 @@ type CopyKubeConfigForControlPlane struct {
|
||||
}
|
||||
|
||||
func (c *CopyKubeConfigForControlPlane) Execute(runtime connector.Runtime) error {
|
||||
createConfigDirCmd := "mkdir -p /root/.kube"
|
||||
getKubeConfigCmd := "cp -f /etc/kubernetes/admin.conf /root/.kube/config"
|
||||
cmd := strings.Join([]string{createConfigDirCmd, getKubeConfigCmd}, " && ")
|
||||
if _, err := runtime.GetRunner().SudoCmd(cmd, false, false); err != nil {
|
||||
targetHome, targetUID, targetGID, err := utils.ResolveSudoUserHomeAndIDs(runtime)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
cmds := []string{
|
||||
"mkdir -p /root/.kube",
|
||||
"cp -f /etc/kubernetes/admin.conf /root/.kube/config",
|
||||
"chmod 0600 /root/.kube/config",
|
||||
fmt.Sprintf("mkdir -p %s", filepath.Join(targetHome, ".kube")),
|
||||
fmt.Sprintf("cp -f /etc/kubernetes/admin.conf %s", filepath.Join(targetHome, ".kube", "config")),
|
||||
fmt.Sprintf("chmod 0600 %s", filepath.Join(targetHome, ".kube", "config")),
|
||||
fmt.Sprintf("chown -R %s:%s %s", targetUID, targetGID, filepath.Join(targetHome, ".kube")),
|
||||
}
|
||||
if _, err := runtime.GetRunner().SudoCmd(strings.Join(cmds, " && "), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "copy kube config failed")
|
||||
}
|
||||
|
||||
userMkdir := "mkdir -p $HOME/.kube"
|
||||
if _, err := runtime.GetRunner().Cmd(userMkdir, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user mkdir $HOME/.kube failed")
|
||||
}
|
||||
|
||||
userCopyKubeConfig := "cp -f /etc/kubernetes/admin.conf $HOME/.kube/config"
|
||||
if _, err := runtime.GetRunner().SudoCmd(userCopyKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user copy /etc/kubernetes/admin.conf to $HOME/.kube/config failed")
|
||||
}
|
||||
|
||||
if _, err := runtime.GetRunner().SudoCmd("chmod 0600 $HOME/.kube/config", false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chmod $HOME/.kube/config failed")
|
||||
}
|
||||
|
||||
// userId, err := runtime.GetRunner().Cmd("echo $(id -u)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
// }
|
||||
|
||||
// userGroupId, err := runtime.GetRunner().Cmd("echo $(id -g)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
// }
|
||||
|
||||
userId, err := runtime.GetRunner().Cmd("echo $SUDO_UID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
}
|
||||
|
||||
userGroupId, err := runtime.GetRunner().Cmd("echo $SUDO_GID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
}
|
||||
|
||||
chownKubeConfig := fmt.Sprintf("chown -R %s:%s $HOME/.kube", userId, userGroupId)
|
||||
if _, err := runtime.GetRunner().SudoCmd(chownKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chown user kube config failed")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -521,53 +493,23 @@ func (s *SyncKubeConfigToWorker) Execute(runtime connector.Runtime) error {
|
||||
if v, ok := s.PipelineCache.Get(common.ClusterStatus); ok {
|
||||
cluster := v.(*KubernetesStatus)
|
||||
|
||||
createConfigDirCmd := "mkdir -p /root/.kube"
|
||||
if _, err := runtime.GetRunner().SudoCmd(createConfigDirCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "create .kube dir failed")
|
||||
}
|
||||
|
||||
syncKubeConfigForRootCmd := fmt.Sprintf("echo '%s' > %s", cluster.KubeConfig, "/root/.kube/config")
|
||||
if _, err := runtime.GetRunner().SudoCmd(syncKubeConfigForRootCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config for root failed")
|
||||
}
|
||||
|
||||
if _, err := runtime.GetRunner().SudoCmd("chmod 0600 /root/.kube/config", false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chmod $HOME/.kube/config failed")
|
||||
}
|
||||
|
||||
userConfigDirCmd := "mkdir -p $HOME/.kube"
|
||||
if _, err := runtime.GetRunner().Cmd(userConfigDirCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "user mkdir $HOME/.kube failed")
|
||||
}
|
||||
|
||||
syncKubeConfigForUserCmd := fmt.Sprintf("echo '%s' > %s", cluster.KubeConfig, "$HOME/.kube/config")
|
||||
if _, err := runtime.GetRunner().Cmd(syncKubeConfigForUserCmd, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config for normal user failed")
|
||||
}
|
||||
|
||||
// userId, err := runtime.GetRunner().Cmd("echo $(id -u)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
// }
|
||||
|
||||
// userGroupId, err := runtime.GetRunner().Cmd("echo $(id -g)", false, false)
|
||||
// if err != nil {
|
||||
// return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
// }
|
||||
|
||||
userId, err := runtime.GetRunner().Cmd("echo $SUDO_UID", false, false)
|
||||
targetHome, targetUID, targetGID, err := utils.ResolveSudoUserHomeAndIDs(runtime)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user id failed")
|
||||
return err
|
||||
}
|
||||
targetKubeConfigPath := filepath.Join(targetHome, ".kube", "config")
|
||||
|
||||
userGroupId, err := runtime.GetRunner().Cmd("echo $SUDO_GID", false, false)
|
||||
if err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "get user group id failed")
|
||||
cmds := []string{
|
||||
"mkdir -p /root/.kube",
|
||||
fmt.Sprintf("echo '%s' > %s", cluster.KubeConfig, "/root/.kube/config"),
|
||||
"chmod 0600 /root/.kube/config",
|
||||
fmt.Sprintf("mkdir -p %s", filepath.Join(targetHome, ".kube")),
|
||||
fmt.Sprintf("echo '%s' > %s", cluster.KubeConfig, targetKubeConfigPath),
|
||||
fmt.Sprintf("chmod 0600 %s", targetKubeConfigPath),
|
||||
fmt.Sprintf("chown -R %s:%s %s", targetUID, targetGID, filepath.Join(targetHome, ".kube")),
|
||||
}
|
||||
|
||||
chownKubeConfig := fmt.Sprintf("chown -R %s:%s -R $HOME/.kube", userId, userGroupId)
|
||||
if _, err := runtime.GetRunner().SudoCmd(chownKubeConfig, false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "chown user kube config failed")
|
||||
if _, err := runtime.GetRunner().SudoCmd(strings.Join(cmds, " && "), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "sync kube config failed")
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
@@ -396,3 +396,17 @@ func (t *DeleteTerminusData) Execute(runtime connector.Runtime) error {
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
type CreateSharedLibDir struct {
|
||||
common.KubeAction
|
||||
}
|
||||
|
||||
func (t *CreateSharedLibDir) Execute(runtime connector.Runtime) error {
|
||||
if runtime.GetSystemInfo().IsDarwin() {
|
||||
return nil
|
||||
}
|
||||
if _, err := runtime.GetRunner().SudoCmd(fmt.Sprintf("mkdir -p %s && chown 1000:1000 %s", OlaresSharedLibDir, OlaresSharedLibDir), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "failed to create shared lib dir")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -38,12 +38,6 @@ type InstallOsSystem struct {
|
||||
}
|
||||
|
||||
func (t *InstallOsSystem) Execute(runtime connector.Runtime) error {
|
||||
if !runtime.GetSystemInfo().IsDarwin() {
|
||||
if _, err := runtime.GetRunner().SudoCmd(fmt.Sprintf("mkdir -p %s && chown 1000:1000 %s", storage.OlaresSharedLibDir, storage.OlaresSharedLibDir), false, false); err != nil {
|
||||
return errors.Wrap(errors.WithStack(err), "failed to create shared lib dir")
|
||||
}
|
||||
}
|
||||
|
||||
config, err := ctrl.GetConfig()
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -367,6 +361,11 @@ func (m *InstallOsSystemModule) Init() {
|
||||
Action: &CreateUserEnvConfigMap{},
|
||||
}
|
||||
|
||||
createSharedLibDir := &task.LocalTask{
|
||||
Name: "CreateSharedLibDir",
|
||||
Action: &storage.CreateSharedLibDir{},
|
||||
}
|
||||
|
||||
installOsSystem := &task.LocalTask{
|
||||
Name: "InstallOsSystem",
|
||||
Action: &InstallOsSystem{},
|
||||
@@ -399,6 +398,7 @@ func (m *InstallOsSystemModule) Init() {
|
||||
m.Tasks = []task.Interface{
|
||||
applySystemEnv,
|
||||
createUserEnvConfigMap,
|
||||
createSharedLibDir,
|
||||
installOsSystem,
|
||||
createBackupConfigMap,
|
||||
checkSystemService,
|
||||
|
||||
@@ -321,3 +321,54 @@ func GetBufIOReaderOfTerminalInput() (*bufio.Reader, error) {
|
||||
}
|
||||
return bufio.NewReader(tty), nil
|
||||
}
|
||||
|
||||
// ResolveSudoUserHomeAndIDs resolves the home directory, uid, and gid for the user
|
||||
// who invoked sudo. If not running under sudo, it falls back to the current user.
|
||||
// This is useful for commands that need to operate on the invoking user's home
|
||||
// directory rather than /root when running with sudo.
|
||||
func ResolveSudoUserHomeAndIDs(runtime connector.Runtime) (home, uid, gid string, err error) {
|
||||
uid, err = runtime.GetRunner().Cmd("echo ${SUDO_UID:-}", false, false)
|
||||
if err != nil {
|
||||
return "", "", "", errors.Wrap(errors.WithStack(err), "get SUDO_UID failed")
|
||||
}
|
||||
gid, err = runtime.GetRunner().Cmd("echo ${SUDO_GID:-}", false, false)
|
||||
if err != nil {
|
||||
return "", "", "", errors.Wrap(errors.WithStack(err), "get SUDO_GID failed")
|
||||
}
|
||||
uid = strings.TrimSpace(uid)
|
||||
gid = strings.TrimSpace(gid)
|
||||
|
||||
if uid == "" {
|
||||
uid, err = runtime.GetRunner().Cmd("id -u", false, false)
|
||||
if err != nil {
|
||||
return "", "", "", errors.Wrap(errors.WithStack(err), "get current uid failed")
|
||||
}
|
||||
gid, err = runtime.GetRunner().Cmd("id -g", false, false)
|
||||
if err != nil {
|
||||
return "", "", "", errors.Wrap(errors.WithStack(err), "get current gid failed")
|
||||
}
|
||||
uid = strings.TrimSpace(uid)
|
||||
gid = strings.TrimSpace(gid)
|
||||
}
|
||||
|
||||
home, err = runtime.GetRunner().Cmd(fmt.Sprintf(`getent passwd %s | awk -F: 'NR==1{print $6; exit}'`, uid), false, false)
|
||||
if err != nil {
|
||||
home = ""
|
||||
}
|
||||
home = strings.TrimSpace(home)
|
||||
if home == "" {
|
||||
home, _ = runtime.GetRunner().Cmd(fmt.Sprintf(`awk -F: -v uid=%s '$3==uid {print $6; exit}' /etc/passwd 2>/dev/null`, uid), false, false)
|
||||
home = strings.TrimSpace(home)
|
||||
}
|
||||
if home == "" {
|
||||
home, err = runtime.GetRunner().Cmd("echo $HOME", false, false)
|
||||
if err != nil {
|
||||
return "", "", "", errors.Wrap(errors.WithStack(err), "get HOME failed")
|
||||
}
|
||||
home = strings.TrimSpace(home)
|
||||
}
|
||||
if home == "" {
|
||||
return "", "", "", errors.New("resolve user home failed")
|
||||
}
|
||||
return home, uid, gid, nil
|
||||
}
|
||||
|
||||
@@ -84,8 +84,15 @@ func (p *proxyServer) Start() error {
|
||||
clientIp = h
|
||||
}
|
||||
}
|
||||
|
||||
if c.IsWebSocket() {
|
||||
ctx = context.WithValue(ctx, WSKey, true)
|
||||
swp := c.Request().Header.Get("Sec-WebSocket-Protocol")
|
||||
authToken := c.Request().Header.Get("X-Authorization")
|
||||
if len(authToken) == 0 && len(swp) > 0 {
|
||||
// handle missing auth token for websocket
|
||||
c.Request().Header.Set("X-Authorization", swp)
|
||||
}
|
||||
}
|
||||
r := c.Request().WithContext(ctx)
|
||||
if clientIp != "" {
|
||||
@@ -243,7 +250,7 @@ func (p *proxyServer) customDialContext(d *net.Dialer) func(ctx context.Context,
|
||||
}
|
||||
|
||||
if isWs {
|
||||
klog.Info("WebSocket connection detected, using upgraded dialer")
|
||||
klog.Info("WebSocket connection detected, using upgraded dialer, ", addr)
|
||||
return tlsDial(ctx, d, func(ctx context.Context, network, addr string) (net.Conn, error) {
|
||||
return proxyDial(ctx, d, network, newAddr)
|
||||
}, network, addr, &tls.Config{InsecureSkipVerify: true})
|
||||
|
||||
@@ -557,6 +557,8 @@ const side = {
|
||||
{
|
||||
text: "Stirling PDF",
|
||||
link: "/use-cases/stirling-pdf",
|
||||
text: "PDFMathTranslate",
|
||||
link: "/use-cases/pdfmathtranslate",
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -630,65 +632,46 @@ const side = {
|
||||
link: "/developer/install/cli/olares-cli",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "gpu", link: "/developer/install/cli/gpu" },
|
||||
{ text: "osinfo", link: "/developer/install/cli/osinfo" },
|
||||
{ text: "node", link: "/developer/install/cli/node" },
|
||||
{
|
||||
text: "backups",
|
||||
link: "/developer/install/cli/backups",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "backup", link: "/developer/install/cli/backups-backup" },
|
||||
{ text: "download", link: "/developer/install/cli/backups-download" },
|
||||
{ text: "region", link: "/developer/install/cli/backups-region" },
|
||||
{ text: "backup", link: "/developer/install/cli/backups-backup" },
|
||||
{ text: "restore", link: "/developer/install/cli/backups-restore" },
|
||||
{ text: "snapshots", link: "/developer/install/cli/backups-snapshots" },
|
||||
],
|
||||
},
|
||||
},
|
||||
{ text: "change-ip", link: "/developer/install/cli/change-ip" },
|
||||
{ text: "disk", link: "/developer/install/cli/disk" },
|
||||
{ text: "download", link: "/developer/install/cli/download" },
|
||||
{ text: "gpu", link: "/developer/install/cli/gpu" },
|
||||
{ text: "info", link: "/developer/install/cli/info" },
|
||||
{ text: "install", link: "/developer/install/cli/install" },
|
||||
{ text: "logs", link: "/developer/install/cli/logs" },
|
||||
{ text: "node", link: "/developer/install/cli/node" },
|
||||
{ text: "osinfo", link: "/developer/install/cli/osinfo" },
|
||||
{ text: "precheck", link: "/developer/install/cli/precheck" },
|
||||
{ text: "prepare", link: "/developer/install/cli/prepare" },
|
||||
{ text: "release", link: "/developer/install/cli/release" },
|
||||
{ text: "start", link: "/developer/install/cli/start" },
|
||||
{ text: "stop", link: "/developer/install/cli/stop" },
|
||||
{ text: "uninstall", link: "/developer/install/cli/uninstall" },
|
||||
{ text: "upgrade", link: "/developer/install/cli/upgrade" },
|
||||
{
|
||||
text: "change-ip",
|
||||
link: "/developer/install/cli/change-ip",
|
||||
},
|
||||
{
|
||||
text: "download",
|
||||
link: "/developer/install/cli/download",
|
||||
},
|
||||
{ text: "info", link: "/developer/install/cli/info" },
|
||||
{
|
||||
text: "install",
|
||||
link: "/developer/install/cli/install",
|
||||
},
|
||||
{
|
||||
text: "user activate",
|
||||
link: "/developer/install/cli/user-activate",
|
||||
},
|
||||
{
|
||||
text: "logs",
|
||||
link: "/developer/install/cli/logs",
|
||||
},
|
||||
{
|
||||
text: "precheck",
|
||||
link: "/developer/install/cli/precheck",
|
||||
},
|
||||
{
|
||||
text: "prepare",
|
||||
link: "/developer/install/cli/prepare",
|
||||
},
|
||||
{
|
||||
text: "release",
|
||||
link: "/developer/install/cli/release",
|
||||
},
|
||||
{
|
||||
text: "start",
|
||||
link: "/developer/install/cli/start",
|
||||
},
|
||||
{
|
||||
text: "stop",
|
||||
link: "/developer/install/cli/stop",
|
||||
},
|
||||
{
|
||||
text: "uninstall",
|
||||
link: "/developer/install/cli/uninstall",
|
||||
text: "user",
|
||||
link: "/developer/install/cli/user",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "activate", link: "/developer/install/cli/user-activate" },
|
||||
{ text: "create", link: "/developer/install/cli/user-create" },
|
||||
{ text: "delete", link: "/developer/install/cli/user-delete" },
|
||||
{ text: "get", link: "/developer/install/cli/user-get" },
|
||||
{ text: "list", link: "/developer/install/cli/user-list" },
|
||||
{ text: "reset-password", link: "/developer/install/cli/user-reset-password" },
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
@@ -608,72 +608,52 @@ const side = {
|
||||
},
|
||||
{
|
||||
text: "Olares CLI",
|
||||
collapsed: true,
|
||||
link: "/zh/developer/install/cli/olares-cli",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "gpu", link: "/zh/developer/install/cli/gpu" },
|
||||
{ text: "osinfo", link: "/zh/developer/install/cli/osinfo" },
|
||||
{ text: "node", link: "/zh/developer/install/cli/node" },
|
||||
{
|
||||
text: "backups",
|
||||
link: "/zh/developer/install/cli/backups",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "backup", link: "/zh/developer/install/cli/backups-backup" },
|
||||
{ text: "download", link: "/zh/developer/install/cli/backups-download" },
|
||||
{ text: "region", link: "/zh/developer/install/cli/backups-region" },
|
||||
{ text: "backup", link: "/zh/developer/install/cli/backups-backup" },
|
||||
{ text: "restore", link: "/zh/developer/install/cli/backups-restore" },
|
||||
{ text: "snapshots", link: "/zh/developer/install/cli/backups-snapshots" },
|
||||
],
|
||||
},
|
||||
},
|
||||
{ text: "change-ip", link: "/zh/developer/install/cli/change-ip" },
|
||||
{ text: "disk", link: "/zh/developer/install/cli/disk" },
|
||||
{ text: "download", link: "/zh/developer/install/cli/download" },
|
||||
{ text: "gpu", link: "/zh/developer/install/cli/gpu" },
|
||||
{ text: "info", link: "/zh/developer/install/cli/info" },
|
||||
{ text: "install", link: "/zh/developer/install/cli/install" },
|
||||
{ text: "logs", link: "/zh/developer/install/cli/logs" },
|
||||
{ text: "node", link: "/zh/developer/install/cli/node" },
|
||||
{ text: "osinfo", link: "/zh/developer/install/cli/osinfo" },
|
||||
{ text: "precheck", link: "/zh/developer/install/cli/precheck" },
|
||||
{ text: "prepare", link: "/zh/developer/install/cli/prepare" },
|
||||
{ text: "release", link: "/zh/developer/install/cli/release" },
|
||||
{ text: "start", link: "/zh/developer/install/cli/start" },
|
||||
{ text: "stop", link: "/zh/developer/install/cli/stop" },
|
||||
{ text: "uninstall", link: "/zh/developer/install/cli/uninstall" },
|
||||
{ text: "upgrade", link: "/zh/developer/install/cli/upgrade" },
|
||||
{
|
||||
text: "change-ip",
|
||||
link: "/zh/developer/install/cli/change-ip",
|
||||
},
|
||||
{
|
||||
text: "download",
|
||||
link: "/zh/developer/install/cli/download",
|
||||
},
|
||||
{ text: "info", link: "/zh/developer/install/cli/info" },
|
||||
{
|
||||
text: "install",
|
||||
link: "/zh/developer/install/cli/install",
|
||||
},
|
||||
{
|
||||
text: "user activate",
|
||||
link: "/zh/developer/install/cli/user-activate",
|
||||
},
|
||||
{
|
||||
text: "logs",
|
||||
link: "/zh/developer/install/cli/logs",
|
||||
},
|
||||
{
|
||||
text: "precheck",
|
||||
link: "/zh/developer/install/cli/precheck",
|
||||
},
|
||||
{
|
||||
text: "prepare",
|
||||
link: "/zh/developer/install/cli/prepare",
|
||||
},
|
||||
{
|
||||
text: "release",
|
||||
link: "/zh/developer/install/cli/release",
|
||||
},
|
||||
{
|
||||
text: "start",
|
||||
link: "/zh/developer/install/cli/start",
|
||||
},
|
||||
{
|
||||
text: "stop",
|
||||
link: "/zh/developer/install/cli/stop",
|
||||
},
|
||||
{
|
||||
text: "uninstall",
|
||||
link: "/zh/developer/install/cli/uninstall",
|
||||
text: "user",
|
||||
link: "/zh/developer/install/cli/user",
|
||||
collapsed: true,
|
||||
items: [
|
||||
{ text: "activate", link: "/zh/developer/install/cli/user-activate" },
|
||||
{ text: "create", link: "/zh/developer/install/cli/user-create" },
|
||||
{ text: "delete", link: "/zh/developer/install/cli/user-delete" },
|
||||
{ text: "get", link: "/zh/developer/install/cli/user-get" },
|
||||
{ text: "list", link: "/zh/developer/install/cli/user-list" },
|
||||
{ text: "reset-password", link: "/zh/developer/install/cli/user-reset-password" },
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
{
|
||||
text: "版本说明",
|
||||
link: "/zh/developer/install/versioning",
|
||||
@@ -719,7 +699,7 @@ const side = {
|
||||
text: "OlaresManifest",
|
||||
link: "/zh/developer/develop/package/manifest",
|
||||
},
|
||||
/*/{
|
||||
/*{
|
||||
text: "推荐算法",
|
||||
link: "/zh/developer/develop/package/recommend",
|
||||
},*/
|
||||
|
||||
@@ -65,7 +65,7 @@ These options apply to all backends:
|
||||
kubectl get terminus -o jsonpath='{.items[*].metadata.labels.bytetrade\.io/cluster-id}'
|
||||
```
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Backup to Tencent COS
|
||||
olares-cli backups backup cos --path /data --repo-name my_repo \
|
||||
|
||||
@@ -12,7 +12,7 @@ olares-cli backups download [options]
|
||||
|--------------------|-----------|--------------------------------------------------------|-------------------------|--------------------|
|
||||
| `--download-cdn-url`| | Specifies the CDN URL for downloading the Restic tool. | No | System default URL |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
## Example
|
||||
## Examples
|
||||
```bash d
|
||||
# Download Restic using a custom CDN URL
|
||||
olares-cli backups download --download-cdn-url https://custom-cdn.example.com/restic
|
||||
|
||||
@@ -17,7 +17,7 @@ olares-cli backups region space [options]
|
||||
|
||||
1. To retrieve the access token and Olares DID, inspect the payload of the network requests made by the Olares Space web interface after logging in. The `token` field corresponds to the access token, and the `userid` field corresponds to the Olares DID.
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Query cloud name and region ID
|
||||
olares-cli backups region space \
|
||||
|
||||
@@ -69,7 +69,7 @@ These options apply to all backends:
|
||||
kubectl get terminus -o jsonpath='{.items[*].metadata.labels.bytetrade\.io/cluster-id}'
|
||||
```
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Restore the data from Tencent COS
|
||||
olares-cli backups restore cos --path /data_restore --repo-name my_repo \
|
||||
|
||||
@@ -61,7 +61,7 @@ These options apply to all backends:
|
||||
kubectl get terminus -o jsonpath='{.items[*].metadata.labels.bytetrade\.io/cluster-id}'
|
||||
```
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# List snapshots for Tencent COS
|
||||
olares-cli backups snapshots cos --repo-name my_repo \
|
||||
|
||||
33
docs/developer/install/cli/disk.md
Normal file
@@ -0,0 +1,33 @@
|
||||
# `disk`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `disk` command provides a set of tools to manage storage resources in the Olares system. It is specifically used for managing LVM-based storage configurations.
|
||||
|
||||
|
||||
```bash
|
||||
olares-cli disk <subcommand>
|
||||
```
|
||||
|
||||
## Subcommands
|
||||
|
||||
| Subcommand | Description |
|
||||
|--|--|
|
||||
| `extend` | Extends Olares storage capacity on LVM-based installations. |
|
||||
| `list-unmounted` | Lists unmounted disks. |
|
||||
|
||||
## Options
|
||||
|
||||
| Name | Shorthand | Usage |
|
||||
|--|--|--|
|
||||
| `--help` | `-h` | Displays help information.|
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# List all disks that are connected but not mounted
|
||||
olares-cli disk list-unmounted
|
||||
|
||||
# Extend Olares storage by adding newly detected unmounted disks
|
||||
olares-cli disk extend
|
||||
```
|
||||
@@ -32,7 +32,7 @@ olares-cli gpu <subcommand> [options]
|
||||
| `--version`| `-v` | Specifies the Olares version for GPU drivers and components. <br>Version values follow the format `x.y.z` (e.g., `1.10.0`) or include a build date (e.g., `1.10.0-20241109`).<br> Refer to the [GitHub Releases page](https://github.com/beclab/Olares/releases) for available versions. | No | Current version |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Install GPU drivers and dependencies to a specific directory
|
||||
|
||||
@@ -7,7 +7,7 @@ The `info` command displays general information about the installed Olares versi
|
||||
olares-cli info
|
||||
```
|
||||
|
||||
## Flag
|
||||
## Options
|
||||
|
||||
| Name | Shorthand | Usage |
|
||||
|----------|-----------|---------------------------|
|
||||
|
||||
@@ -28,7 +28,7 @@ olares-cli logs [option]
|
||||
| `--output-dir` | | Saves logs to the specified directory. Creates the directory if it does not exist. | No | `./olares-logs` |
|
||||
| `--since` | | Fetches logs newer than a specified relative duration (e.g., `5s`, `2m`, `3h`). | No | `7d` |
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Collect all logs with default settings
|
||||
olares-cli logs
|
||||
|
||||
@@ -29,7 +29,7 @@ olares-cli node <subcommand> [options]
|
||||
| `--version` | `-v` | Specifies the Olares version. <br>Version values follow the format `x.y.z` (e.g., `1.10.0`) or include a build date (e.g., `1.10.0-20241109`).<br> Refer to the [GitHub Releases page](https://github.com/beclab/Olares/releases) for available versions. | No | Current version |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A | |
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Retrieve system information from a master node at IP 192.168.1.15
|
||||
|
||||
@@ -28,12 +28,13 @@ wsl -d Ubuntu
|
||||
## Syntax
|
||||
The Olares CLI uses the following syntax:
|
||||
|
||||
> `olares-cli command [subcommand] [option]`
|
||||
> `olares-cli command [subcommand] [argument] [options] `
|
||||
|
||||
where
|
||||
- `command`: Specifies the main operation you want to perform. For example, `olares-cli install`.
|
||||
- `subcommand`: Further specifies the task for commands that support additional operations. For example, `wizard` or `component`.
|
||||
- `option`: Optional arguments that modify the behavior of the `command`. Options include flags and options with arguments.
|
||||
- `argument`: Specifies the target resource or input data for the command, typically an ID, name, or file path. For example, in `olares-cli user activate <Olares ID> [options]`, `<Olares ID>` is the argument.
|
||||
- `options`: Optional arguments that modify the behavior of the `command`. Options include flags and options with arguments.
|
||||
|
||||
Olares CLI allows you to temporarily override certain Olares default settings. Each option applies only to the command in which it is used.
|
||||
|
||||
@@ -43,21 +44,23 @@ To get detailed help for any command, run `olares-cli help`.
|
||||
|
||||
## Available CLI commands
|
||||
|
||||
| Operation | Syntax | Description |
|
||||
|--------------------|----------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------|
|
||||
| `gpu` | `olares-cli gpu <subcommand> [option]` | Manages GPU-related operations. |
|
||||
| `info` | `olares-cli info <subcommand> [option]` | Displays general information about the operating system of the current device. |
|
||||
| `node` | `olares-cli node <subcommand> [option]` | Manages node-related operations. |
|
||||
| `backups` | `olares-cli backups <subcommand> [option]` | Manages backup-related operations. |
|
||||
| `change-ip` | `olares-cli change-ip [option]` | Changes the IP address of the Olares OS. |
|
||||
| `download` | `olares-cli download <subcommand> [option]` | Downloads specific resources. |
|
||||
| `info` | `olares-cli info [option]` | Displays general information about the downloaded Olares OS. |
|
||||
| `install` | `olares-cli install [option]` | Deploys system-level and user-level components of Olares. |
|
||||
| `logs` | `olares-cli logs [option]` | Collects logs from Olares system components for debugging and troubleshooting. |
|
||||
| `precheck` | `olares-cli precheck [option]` | Verifies whether the system environment meets all requirements for Olares installation. |
|
||||
| `prepare` | `olares-cli prepare [option]` | Prepares the environment for the installation process, including setting up essential services and configurations of Olares. |
|
||||
| `release` | `olares-cli release [option]` | Packages Olares installation resources for distribution or deployment. |
|
||||
| `start` | `olares-cli start [option]` | Starts Olares services and components. |
|
||||
| `stop` | `olares-cli stop [option]` | Stops Olares services and components. |
|
||||
| `uninstall` | `olares-cli uninstall [option]` | Uninstalls Olares completely, or roll back the installation to a specific phase. |
|
||||
|
||||
| Operation | Syntax | Description |
|
||||
|--|--|--|
|
||||
| `backups` | `olares-cli backups <subcommand> [options]` | Manages backup-related operations. |
|
||||
| `change-ip` | `olares-cli change-ip [options]` | Changes the IP address of the Olares OS. |
|
||||
| `disk` | `olares-cli disk <subcommand>` | Manages storage resources in the Olares system. |
|
||||
| `download` | `olares-cli download <subcommand> [options]` | Downloads specific resources. |
|
||||
| `gpu` | `olares-cli gpu <subcommand> [options]` | Manages GPU-related operations. |
|
||||
| `info` | `olares-cli info [options]` | Displays general information about the downloaded Olares OS. |
|
||||
| `install` | `olares-cli install [options]` | Deploys system-level and user-level components of Olares. |
|
||||
| `logs` | `olares-cli logs [options]` | Collects logs from Olares system components for debugging and troubleshooting. |
|
||||
| `node` | `olares-cli node <subcommand> [options]` | Manages node-related operations. |
|
||||
| `osinfo` | `olares-cli osinfo <subcommand> [options]` | Displays general information about the operating system of the current device. |
|
||||
| `precheck` | `olares-cli precheck [options]` | Verifies whether the system environment meets all requirements for Olares installation. |
|
||||
| `prepare` | `olares-cli prepare [options]` | Prepares the environment for the installation process, including setting up essential services and configurations of Olares. |
|
||||
| `release` | `olares-cli release [options]` | Packages Olares installation resources for distribution or deployment. |
|
||||
| `start` | `olares-cli start [options]` | Starts Olares services and components. |
|
||||
| `stop` | `olares-cli stop [options]` | Stops Olares services and components. |
|
||||
| `uninstall` | `olares-cli uninstall [options]` | Uninstalls Olares completely, or roll back the installation to a specific phase. |
|
||||
| `upgrade` | `olares-cli upgrade <subcommand> [options]` | Upgrades Olares and checks upgrade readiness and compatibility.|
|
||||
| `user` | `olares-cli user <subcommand> [options]`| Manages users in the Olares system |
|
||||
@@ -8,13 +8,13 @@ The `osinfo` command provides detailed information about the operating system of
|
||||
olares-cli osinfo <subcommand> [options]
|
||||
```
|
||||
|
||||
## Subcommand
|
||||
## Subcommands
|
||||
|
||||
| Subcommand | Description |
|
||||
|------------|----------------------------------------------------------------------|
|
||||
| `show` | Prints information about the operating system of the current device. |
|
||||
|
||||
## Flag
|
||||
## Options
|
||||
|
||||
| Name | Short | Description |
|
||||
|--------------|-------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
|
||||
@@ -18,7 +18,7 @@ olares-cli prepare [option]
|
||||
| `--version` | `-v` | Specifies the Olares version. <br>Version values follow the format `x.y.z` (e.g., `1.10.0`) or include a build date (e.g., `1.10.0-20241109`).<br> Refer to the [GitHub Releases page](https://github.com/beclab/Olares/releases) for available versions. | No | Current version |
|
||||
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Uses JuiceFS as the root filesystem
|
||||
olares-cli prepare --with-juicefs=true
|
||||
|
||||
@@ -12,7 +12,7 @@ olares-cli start [option]
|
||||
After executing this command, allow 5-8 minutes for all Olares components to restart. You can verify the status of all pods by running `kubectl get pods -A` or by simply trying to access your Olares desktop.
|
||||
:::
|
||||
|
||||
## Option
|
||||
## Options
|
||||
|
||||
| Name | Shorthand | Usage |
|
||||
|------------------|-----------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
|
||||
@@ -15,7 +15,7 @@ olares-cli stop [option]
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--timeout` | | Sets the maximum time to wait for a graceful shutdown before using SIGKILL (e.g., `5s`, `2m`, `3h`). | No | `1m` |
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
```bash
|
||||
# Stop the Olares system
|
||||
olares-cli stop
|
||||
|
||||
53
docs/developer/install/cli/upgrade.md
Normal file
@@ -0,0 +1,53 @@
|
||||
# `upgrade`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `upgrade` command provides a set of tools for upgrading Olares and checking upgrade readiness and compatibility.
|
||||
|
||||
```bash
|
||||
olares-cli upgrade <subcommand> [options]
|
||||
```
|
||||
|
||||
## Subcommands
|
||||
|
||||
| Subcommand | Aliases | Description |
|
||||
|--|--|--|
|
||||
| `precheck` | | Prechecks Olares for upgrade. |
|
||||
| `spec` | `current-spec` | Gets the upgrade spec of the current CLI version. |
|
||||
| `viable` | | Determines whether upgrade can be directly performed upon a base version. |
|
||||
|
||||
## Global options
|
||||
|
||||
These options apply to the main `upgrade` command and are inherited by its subcommands where applicable.
|
||||
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--base-dir` | `-b` | Sets the base directory for Olares packages. | No | `$HOME/.olares` |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--version` | `-v` | Sets the target Olares version to upgrade to. For example, `1.10.0`, `1.10.0-20241109`. | No | N/A |
|
||||
|
||||
## Options for `viable`
|
||||
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--base` | `-b` | Base version to check. | No | Current Olares system version |
|
||||
|
||||
:::warning Option conflict
|
||||
The `-b` shorthand is used by the parent command for `--base-dir`. However, when running `upgrade viable`, `-b` specifically refers to `--base`.
|
||||
:::
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Check whether the current system can be upgraded directly
|
||||
olares-cli upgrade viable
|
||||
|
||||
# Check upgrade viability from a specific base version
|
||||
olares-cli upgrade viable --base 1.9.0
|
||||
|
||||
# Run pre-upgrade checks
|
||||
olares-cli upgrade precheck
|
||||
|
||||
# View the upgrade spec of the current CLI
|
||||
olares-cli upgrade spec
|
||||
```
|
||||
@@ -1,8 +1,9 @@
|
||||
# `user activate`
|
||||
# `activate`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `user activate` command activates an existing Olares account. It requires the user's Olares ID, password, and 12-word mnemonic phrase to complete the activation. This command typically requires administrator privileges (`sudo`).
|
||||
The `activate` subcommand activates an existing Olares account. It requires the user's Olares ID, password, and 12-word mnemonic phrase to complete the activation.
|
||||
|
||||
|
||||
```bash
|
||||
olares-cli user activate <Olares ID> [options]
|
||||
@@ -12,31 +13,32 @@ olares-cli user activate <Olares ID> [options]
|
||||
|
||||
| Argument | Description | Required|
|
||||
|--|--|--|
|
||||
| `<Olares ID>` | Specifies the unique identifier for the Olares user account to be activated. <br>Similar to an email address(e.g., `alice123@olares.com`).| **Yes** |
|
||||
| `<Olares ID>` | Specifies the unique identifier for the Olares user account <br>to be activated. <br>Similar to an email address like `alice123@olares.com`.| Yes |
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
| Option | Short| Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--bfl` | | Specifies the Backend For Launcher (BFL) service URL (e.g., `https://example.com`). | No | `http://127.0.0.1:30180` |
|
||||
| `--bfl` | | Specifies the Backend For Launcher (BFL) service URL, such as `https://example.com`. | No | `http://127.0.0.1:30180` |
|
||||
| `--enable-tunnel` | | Enables or disables tunnel mode for activation. | No | `false` |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--host` | | Specifies the Fast Reverse Proxy (FRP) host. <br>Only used when the `--enable-tunnel` option is set to `true`. | No | N/A |
|
||||
| `--jws` | | Specifies the FRP JWS token.<br>Only used when the `--enable-tunnel` option is set to `true`.| No | N/A |
|
||||
| `--host` | | Specifies the Fast Reverse Proxy (FRP) host. Only used when `--enable-tunnel` option is set to `true`. | No | N/A |
|
||||
| `--jws` | | Specifies the FRP JWS token. Only used when `--enable-tunnel` option is set to `true`.| No | N/A |
|
||||
| `--language` | | Sets the system language. | No | `en-US` |
|
||||
| `--location` | | Sets the timezone location. | No | `Asia/Shanghai` |
|
||||
| `--mnemonic` | | Specifies the 12-word mnemonic phrase required for activation. | **Yes** | N/A |
|
||||
| `--password` | `-p` | Specifies the Olares login password for authentication. | **Yes** | N/A |
|
||||
| `--vault` | | Specifies the Vault service URL (e.g., `https://example.com`). | No | `http://127.0.0.1:30181` |
|
||||
| `--mnemonic` | | Specifies the 12-word mnemonic phrase required for activation. | Yes | N/A |
|
||||
| `--password` | `-p` | Specifies the Olares login password for authentication. | Yes | N/A |
|
||||
| `--reset-password` | | Specifies the new password to set during password reset. This option is required only when performing a password reset. | No | N/A |
|
||||
| `--vault` | | Specifies the Vault service URL, such as `https://example.com`. | No | `http://127.0.0.1:30180` |
|
||||
|
||||
## Example
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Activate an Olares user account
|
||||
sudo olares-cli user activate alice@olares.com -p "HerPassWord" --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
olares-cli user activate alic123e@olares.com -p "HerPassWord" --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
|
||||
# Activate an Olares user account with tunnel mode enabled
|
||||
sudo olares-cli user activate david@olares.com -p "HisPassWord" --enable-tunnel --host "frp-gateway.olares.com" --jws "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.demo.signature" --bfl http://127.0.0.1:30180 --vault http://127.0.0.1:30180/server --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
olares-cli user activate david456@olares.com -p "HisPassWord" --enable-tunnel --host "frp-gateway.olares.com" --jws "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.demo.signature" --bfl http://127.0.0.1:30180 --vault http://127.0.0.1:30180/server --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
|
||||
# Activate an Olares user account with specific language and timezone settings
|
||||
sudo olares-cli user activate carol@olares.com -p "AnotherPassWord" --mnemonic "alpha beta gamma delta epsilon zeta eta theta iota kappa lambda mu" --language "en-US" --location "America/New_York"
|
||||
olares-cli user activate carol789@olares.com -p "AnotherPassWord" --mnemonic "alpha beta gamma delta epsilon zeta eta theta iota kappa lambda mu" --language "en-US" --location "America/New_York"
|
||||
```
|
||||
46
docs/developer/install/cli/user-create.md
Normal file
@@ -0,0 +1,46 @@
|
||||
# `create`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `create` subcommand creates a new user account in the Olares system. It allows administrators to define initial settings such as the username, password, role permissions, and resource limits.
|
||||
|
||||
**Aliases**: `create`, `add`, `new`
|
||||
|
||||
```bash
|
||||
olares-cli user create <name> [options]
|
||||
```
|
||||
|
||||
## Arguments
|
||||
|
||||
| Argument | Description | Required|
|
||||
|--|--|--|
|
||||
| `<name>` | Specifies the username for the new account. <br>It is typically the part before the `@` symbol in an Olares ID. <br>For example, `alice123` for `alice123@olares.com`.| Yes |
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--cpu-limit` | `-c` | Sets the CPU limit for the user environment. | No | `1` |
|
||||
| `--description` | | Adds a description for the user account. | No | N/A |
|
||||
| `--display-name` | | Sets the display name for the user. | No | N/A |
|
||||
| `--domain` | | Specifies the domain for the Olares ID. | No | Olares system's domain |
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--kubeconfig` | | Specifies the path to a kubeconfig file. | No | N/A |
|
||||
| `--memory-limit` | `-m` | Sets the memory limit for the user environment. | No | `3G` |
|
||||
| `--password` | `-p` | Sets the initial login password for the user. | No | N/A |
|
||||
| `--role` | `-r` | Sets the user role.<br>Valid values: `owner`, `admin`, `normal`. | No | `normal` |
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Create a basic user with default settings
|
||||
olares-cli user create alice123
|
||||
|
||||
# Create a user with a specified password and role
|
||||
olares-cli user create blake123 -p "StrongPassword123" -r admin
|
||||
|
||||
# Create a user with custom resource limits (2 CPU cores, 4 GB memory)
|
||||
olares-cli user create carol123 --cpu-limit 2 --memory-limit 4G
|
||||
|
||||
# Create a user with display name and description
|
||||
olares-cli user create david123 --display-name "David Smith" --description "Data platform administrator"
|
||||
```
|
||||
30
docs/developer/install/cli/user-delete.md
Normal file
@@ -0,0 +1,30 @@
|
||||
# `delete`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `delete` subcommand permanently removes an existing user account from the Olares system.
|
||||
|
||||
**Aliases**: `delete`, `d`, `del`, `rm`, `remove`
|
||||
|
||||
```bash
|
||||
olares-cli user delete <name> [options]
|
||||
```
|
||||
|
||||
## Arguments
|
||||
|
||||
| Argument | Description | Required|
|
||||
|--|--|--|
|
||||
| `<name>` | Specifies the username of the account to be deleted. <br>It is typically the part before the `@` symbol in an Olares ID. <br>For example, `alice123` for `alice123@olares.com`.| Yes |
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--kubeconfig` | | Specifies the path to a kubeconfig file. | No | N/A |
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Delete a user named alice123
|
||||
olares-cli user delete alice123
|
||||
```
|
||||
33
docs/developer/install/cli/user-get.md
Normal file
@@ -0,0 +1,33 @@
|
||||
# `get`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `get` subcommand retrieves detailed information about a specific Olares user account. The output can be formatted as a table or JSON.
|
||||
|
||||
```bash
|
||||
olares-cli user get <name> [options]
|
||||
```
|
||||
|
||||
## Arguments
|
||||
|
||||
| Argument | Description | Required|
|
||||
|--|--|--|
|
||||
| `<name>` | Specifies the username of the account to retrieve. <br>It is typically the part before the `@` symbol in an Olares ID. <br>For example, `alice123` for `alice123@olares.com`.| Yes |
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--kubeconfig` | | Specifies the path to a kubeconfig file. | No | N/A |
|
||||
| `--no-headers` | | Disables the header row in the output. | No | N/A |
|
||||
| `--output` | `-o` | Specifies the output format. Valid values: `table`, `json`. | No | `table` |
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Get details for user named alice123 in default table format
|
||||
olares-cli user get alice123
|
||||
|
||||
# Get details for user named blake123 in JSON format
|
||||
olares-cli user get blake123 -o json
|
||||
```
|
||||
34
docs/developer/install/cli/user-list.md
Normal file
@@ -0,0 +1,34 @@
|
||||
# `list`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `list` subcommand displays a list of all registered users in the Olares system. You can sort, filter, and format the output to suit your needs.
|
||||
|
||||
**Aliases**: `list`, `ls`, `l`
|
||||
|
||||
```bash
|
||||
olares-cli user list [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--kubeconfig` | | Specifies the path to a kubeconfig file. | No | N/A |
|
||||
| `--no-headers` | | Disables the header row in the output. | No | N/A |
|
||||
| `--output` | `-o`| Specifies the output format. Valid values: `table`, `json`.| No | `table` |
|
||||
| `--reverse` | `-r` | Reverses the sort order of the output. | No | N/A |
|
||||
| `--sort` | | Sorts the output by a specific field.<br> Valid values: `name`, `role`, `create-time`, `memory`, `cpu` | No | N/A |
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# List all users in a table format
|
||||
olares-cli user list
|
||||
|
||||
# List all users in JSON format
|
||||
olares-cli user list -o json
|
||||
|
||||
# List users sorted by role
|
||||
olares-cli user list --sort role
|
||||
```
|
||||
29
docs/developer/install/cli/user-reset-password.md
Normal file
@@ -0,0 +1,29 @@
|
||||
# `reset-password`
|
||||
|
||||
## Synopsis
|
||||
|
||||
The `reset-password` subcommand forcefully resets the login password for a specific user via the authentication provider.
|
||||
|
||||
```bash
|
||||
olares-cli user reset-password <username> [options]
|
||||
```
|
||||
|
||||
## Arguments
|
||||
|
||||
| Argument | Description | Required|
|
||||
|--|--|--|
|
||||
| `<username>` | Specifies the username of the account to reset. <br>It is typically the part before the `@` symbol in an Olares ID. <br>For example, `alice123` for `alice123@olares.com`.| Yes |
|
||||
|
||||
## Options
|
||||
| Option | Shorthand | Usage | Required | Default |
|
||||
|--|--|--|--|--|
|
||||
`--help` | `-h` | Displays help information. | No | N/A |
|
||||
| `--kubeconfig` | | Specifies the path to a kubeconfig file. | No | N/A |
|
||||
| `--password` | `-p` | Specifies the new password for the user. | Yes | N/A |
|
||||
|
||||
## Examples
|
||||
|
||||
```bash
|
||||
# Reset password for user named alice123
|
||||
olares-cli user reset-password alice123 -p "NewSecurePassword456!"
|
||||
```
|
||||
13
docs/developer/install/cli/user.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# `user`
|
||||
The `user` command provides a set of tools to manage users in the Olares system. It allows administrators to create, activate, query, and remove users, as well as reset user passwords.
|
||||
|
||||
## Subcommands
|
||||
|
||||
| Subcommand | Description |
|
||||
|--|--|
|
||||
| `activate` | Activates an existing Olares account. |
|
||||
| `create` | Creates a new user. |
|
||||
| `delete` | Deletes an existing user. |
|
||||
| `get` | Retrieves details of a specific user. |
|
||||
| `list` | Lists all users within the Olares cluster. |
|
||||
| `reset-password` | Forcefully resets a user's password via the authentication provider. |
|
||||
BIN
docs/public/images/manual/use-cases/access-translated-files.png
Normal file
|
After Width: | Height: | Size: 100 KiB |
BIN
docs/public/images/manual/use-cases/copy-localhost-address.png
Normal file
|
After Width: | Height: | Size: 165 KiB |
BIN
docs/public/images/manual/use-cases/download-in-files.png
Normal file
|
After Width: | Height: | Size: 647 KiB |
|
After Width: | Height: | Size: 1.0 MiB |
BIN
docs/public/images/manual/use-cases/install-pdfmathtranslate.png
Normal file
|
After Width: | Height: | Size: 206 KiB |
BIN
docs/public/images/manual/use-cases/local-model-setup.png
Normal file
|
After Width: | Height: | Size: 718 KiB |
BIN
docs/public/images/manual/use-cases/open-pdfmathtranslate.png
Normal file
|
After Width: | Height: | Size: 87 KiB |
BIN
docs/public/images/manual/use-cases/set-translation-scope.png
Normal file
|
After Width: | Height: | Size: 718 KiB |
|
After Width: | Height: | Size: 261 KiB |
@@ -23,5 +23,6 @@ From running AI models to building seamless workflows across your self-hosted se
|
||||
{ title: 'ACE-Step', link: './ace-step.html', tags: ['AI']},
|
||||
{ title: 'Duix.Avatar', link: './duix-avatar.html', tags: ['AI']},
|
||||
{ title: 'Stirling PDF', link: './stirling-pdf.html', tags: ['Productivity']},
|
||||
{ title: 'PDFMathTranslate', link: './pdfmathtranslate.html', tags: ['AI']},
|
||||
]"
|
||||
/>
|
||||
144
docs/use-cases/pdfmathtranslate.md
Normal file
@@ -0,0 +1,144 @@
|
||||
---
|
||||
outline: [2, 4]
|
||||
description: Learn how to install and configure PDFMathTranslate on Olares. This tutorial guides you through using the local AI model Ollama to translate scientific PDFs, preserving original layouts and mathematical formulas.
|
||||
---
|
||||
|
||||
# Translate scientific PDFs while preserving layout
|
||||
|
||||
PDFMathTranslate is an application designed to translate scientific PDF documents while retaining the original layout and mathematical formulas.
|
||||
|
||||
This tutorial provides instructions on how to install and use PDFMathTranslate on Olares, using the local AI model Ollama for translation.
|
||||
|
||||
## Learning objectives
|
||||
|
||||
By the end of this tutorial, you are able to:
|
||||
- Configure the local AI model for PDF translation.
|
||||
- Translate a scientific PDF and manage the output files.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Before you begin, make sure:
|
||||
- Ollama is installed and running in your Olares environment.
|
||||
- At least one model is installed using Ollama. For more information, see [Ollama](ollama.md).
|
||||
|
||||
## Install PDFMathTranslate
|
||||
|
||||
1. Open the Olares Market and search for "PDFMathTranslate".
|
||||
2. Click **Get**, and then click **Install**.
|
||||
|
||||

|
||||
|
||||
3. When the installation finishes, click **Open**. The PDFMathTranslate workspace is displayed.
|
||||
|
||||

|
||||
|
||||
## Translate
|
||||
|
||||
### Upload your PDF document
|
||||
|
||||
:::warning PDF format requirements
|
||||
Ensure that the PDF file is a standard PDF document that is not password-protected or corrupted. The application cannot process invalid PDF files.
|
||||
:::
|
||||
|
||||
In the **File** area, select your input **Type**:
|
||||
- If you select **File**, drag and drop your PDF document into the upload area, or click the area to browse your local storage.
|
||||
|
||||
When the document is uploaded, a preview of it appears in the **Preview** pane on the right.
|
||||
|
||||
- If you select **Link**, enter the link address of the PDF document.
|
||||
|
||||
The **Preview** pane remains blank during this step. The document content only appears in this area after the translation is completed.
|
||||
|
||||
### Configure the translation service
|
||||
|
||||
To use the local AI service Ollama for translation, configure the following settings:
|
||||
|
||||
1. From the **Service** list, select **Ollama**.
|
||||
2. (Optional) To obtain the Ollama host address:
|
||||
|
||||
a. Go to Olares **Settings** > **Application** > **Ollama**.
|
||||
|
||||
b. In the **Entrances** section, click **Ollama API**.
|
||||
|
||||
c. Click **Set up endpoint**, and then click <i class="material-symbols-outlined">content_copy</i> to copy the endpoint address.
|
||||
|
||||
{width=60%}
|
||||
|
||||
3. In the **OLLAMA_HOST** field, enter the Ollama host address.
|
||||
4. In the **OLLAMA_MODEL** field, enter the exact identifier of the Ollama model you have downloaded. For example, `gemma3:4b`.
|
||||
|
||||

|
||||
|
||||
### Select languages and scope
|
||||
|
||||
1. Select the source and target languages:
|
||||
|
||||
a. **Translate from** indicates the original document's language.
|
||||
|
||||
b. **Translate to** indicates the language you want to read.
|
||||
|
||||
:::info
|
||||
PDFMathTranslate does not auto-detect the languages. You must select them manually. Supported languages include English, Simplified Chinese, Traditional Chinese, French, German, Japanese, Korean, Russian, Spanish, and Italian.
|
||||
:::
|
||||
|
||||
2. Specify which pages to translate:
|
||||
* **All**: Translates the entire document.
|
||||
* **First**: Translates only the first page.
|
||||
* **First 5 pages**: Translates the first five pages.
|
||||
* **Others**: Translates a custom range of pages.
|
||||
|
||||

|
||||
|
||||
3. Click **Translate**. The translation starts immediately.
|
||||
|
||||
:::warning
|
||||
Do not click the **Cancel** button during translation. This might cause the process to report an error.
|
||||
:::
|
||||
|
||||
### Download your files
|
||||
|
||||
When the translation is completed, the translated file is displayed in the **Preview** pane, and the application generates three files:
|
||||
|
||||
- Original source file
|
||||
- Translated file
|
||||
- Bilingual version
|
||||
|
||||
You can find these files in the Files app. To download them to your local computer, download them directly from the PDFMathTranslate workspace, or use the Files app.
|
||||
|
||||
#### In PDFMathTranslate workspace
|
||||
|
||||
On the left side of the pdfmathtranslate workspace, in the **Translated** section, click the download button next to the file.
|
||||
|
||||

|
||||
|
||||
#### From Olares Files app
|
||||
|
||||
1. Open the Files app, and then go to **Data** > **pdfmathtranslate** > **pdfmathtranslate**.
|
||||
|
||||

|
||||
|
||||
2. Double-click a file, and then click the download icon in the upper-right corner.
|
||||
|
||||

|
||||
|
||||
## FAQ
|
||||
|
||||
### Why did the translation progress bar disappear?
|
||||
|
||||
If you refresh the page while a translation is running, the progress bar might disappear from the screen. This is a display issue only, and the translation is still processing in the background.
|
||||
|
||||
Wait for it to finish or check the output folder.
|
||||
|
||||
### Will the app keep multiple versions of the same file?
|
||||
|
||||
If you translate the same file name multiple times, the system replaces the previous version with the new one. It does not create numbered copies such as `file_1.pdf`. To keep multiple versions, rename your source file before translating it again.
|
||||
|
||||
### What should I do if the app becomes unresponsive or takes unusually long?
|
||||
|
||||
If the translation takes significantly longer than usual or the application stops responding, the background process might have stalled. To resolve this issue, uninstall and then re-install pdfmathtranslate.
|
||||
|
||||
### How do I perform a clean uninstallation of PDFMathTranslate?
|
||||
|
||||
To completely remove the application and its data:
|
||||
1. Uninstall the app from Market or Desktop. For more information, see [Uninstall applications](../manual/olares/market/market.md#uninstall-applications).
|
||||
2. Open the Files app, go to **Application** > **Data**, and then delete the `pdfmathtranslate` folder.
|
||||
32
docs/zh/developer/install/cli/disk.md
Normal file
@@ -0,0 +1,32 @@
|
||||
# `disk`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`disk`命令提供了一组用于管理 Olares 系统存储资源的工具,主要用于基于 LVM 的存储配置管理。
|
||||
|
||||
```bash
|
||||
olares-cli disk <subcommand>
|
||||
```
|
||||
|
||||
## 子命令
|
||||
|
||||
| 子命令 | 描述 |
|
||||
|--|--|
|
||||
| `extend` | 在基于 LVM 的安装环境中扩展 Olares 的存储容量。 |
|
||||
| `list-unmounted` | 列出未挂载的磁盘。 |
|
||||
|
||||
## 参数标记
|
||||
|
||||
| 名称 | 简写 | 说明 |
|
||||
|--|--|--|
|
||||
| `--help` | `-h` | 显示帮助信息。 |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 列出未挂载的磁盘
|
||||
olares-cli disk list-unmounted
|
||||
|
||||
# 添加新检测到的未挂载磁盘来扩展 Olares 存储
|
||||
olares-cli disk extend
|
||||
```
|
||||
@@ -28,11 +28,12 @@ wsl -d Ubuntu
|
||||
## 语法
|
||||
Olares 命令行工具使用如下语法:
|
||||
|
||||
> `olares-cli 命令 [子命令] [选项]`
|
||||
> `olares-cli 命令 [子命令] [参数] [选项]`
|
||||
|
||||
其中:
|
||||
- `命令`:指定要执行的主要操作,例如 `olares-cli install`。
|
||||
- `子命令`:进一步指定命令的具体任务,适用于支持子操作的命令。例如 `wizard` 或 `component`。
|
||||
- `参数`:指定命令的目标资源或输入数据,通常是 ID、名称或文件路径。例如,在 `olares-cli user activate <Olares ID> [选项]` 中,`<Olares ID>` 就是该命令的参数。
|
||||
- `选项`:可选参数,用于修改命令的行为。包括标志(flags)和带参数的选项。
|
||||
|
||||
通过 Olares 命令行工具,你可以临时覆盖某些 Olares 默认设置。每个选项仅对当前执行的命令生效。
|
||||
@@ -43,21 +44,23 @@ Olares 命令行工具使用如下语法:
|
||||
|
||||
## 可用命令列表
|
||||
|
||||
| 操作 | 语法 | 说明 |
|
||||
|--------------------|-----------------------------------------|--------------------------------|
|
||||
| `gpu` | `olares-cli gpu <子命令> [选项]` | 管理 GPU 相关的操作。 |
|
||||
| `info` | `olares-cli info <子命令> [选项]` | 显示当前设备的操作系统信息。 |
|
||||
| `node` | `olares-cli node <子命令> [选项]` | 管理节点相关的操作。 |
|
||||
| `backups` | `olares-cli backups <子命令> [选项]` | 管理备份相关操作。 |
|
||||
| `change-ip` | `olares-cli change-ip [选项]` | 修改 Olares OS 的 IP 地址。 |
|
||||
| `download` | `olares-cli download <子命令> [选项]` | 下载指定资源。 |
|
||||
| `info` | `olares-cli info [选项]` | 显示已下载的 Olares OS 的常规信息。 |
|
||||
| `install` | `olares-cli install [选项]` | 部署 Olares 的系统级和用户级组件。 |
|
||||
| `logs` | `olares-cli logs [选项]` | 收集 Olares 系统组件的日志,用于调试和故障排查。 |
|
||||
| `precheck` | `olares-cli precheck [选项]` | 检查系统环境是否满足 Olares 安装要求。 |
|
||||
| `prepare` | `olares-cli prepare [选项]` | 为安装过程准备环境,包括设置 Olares 的基础服务和配置 |
|
||||
| `release` | `olares-cli release [选项]` | 打包 Olares 安装资源以供分发或部署。 |
|
||||
| `start` | `olares-cli start [选项]` | 启动 Olares 服务和组件。 |
|
||||
| `stop` | `olares-cli stop [选项]` | 停止 Olares 服务和组件。 |
|
||||
| `uninstall` | `olares-cli uninstall [选项]` | 完全卸载 Olares,或将安装回滚到特定阶段。 |
|
||||
|
||||
| 操作 | 语法 | 说明 |
|
||||
|--|--|--|
|
||||
| `backups` | `olares-cli backups <子命令> [选项]` | 管理备份相关操作。 |
|
||||
| `change-ip` | `olares-cli change-ip [选项]` | 修改 Olares OS 的 IP 地址。 |
|
||||
| `disk` | `olares-cli disk <子命令>` | 管理 Olares 系统存储资源。 |
|
||||
| `download` | `olares-cli download <子命令> [选项]` | 下载指定资源。 |
|
||||
| `gpu` | `olares-cli gpu <子命令> [选项]` | 管理 GPU 相关的操作。 |
|
||||
| `info` | `olares-cli info [选项]` | 显示已下载的 Olares OS 的常规信息。|
|
||||
| `install` | `olares-cli install [选项]` | 部署 Olares 的系统级和用户级组件。|
|
||||
| `logs` | `olares-cli logs [选项]` | 收集 Olares 系统组件的日志,用于调试和故障排查。 |
|
||||
| `node` | `olares-cli node <子命令> [选项]` | 管理节点相关的操作。 |
|
||||
| `osinfo` | `olares-cli osinfo <子命令> [选项]` | 显示当前设备的操作系统信息。 |
|
||||
| `precheck`| `olares-cli precheck [选项]` | 检查系统环境是否满足 Olares 安装要求。|
|
||||
| `prepare` | `olares-cli prepare [选项]` | 为安装过程准备环境,包括设置 Olares 的基础服务和配置。 |
|
||||
| `release` | `olares-cli release [选项]` | 打包 Olares 安装资源以供分发或部署。|
|
||||
| `start` | `olares-cli start [选项]` | 启动 Olares 服务和组件。 |
|
||||
| `stop` | `olares-cli stop [选项]` | 停止 Olares 服务和组件。 |
|
||||
| `uninstall` | `olares-cli uninstall [选项]` | 完全卸载 Olares,或将安装回滚到特定阶段。 |
|
||||
| `upgrade` | `olares-cli upgrade <子命令> [选项]` | 升级 Olares,检查升级准备情况与兼容性。 |
|
||||
| `user` | `olares-cli user <子命令> [选项]`| 管理 Olares 用户。 |
|
||||
53
docs/zh/developer/install/cli/upgrade.md
Normal file
@@ -0,0 +1,53 @@
|
||||
# `upgrade`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`upgrade`命令提供一组用于升级 Olares,检查升级准备情况与兼容性的工具。
|
||||
|
||||
```bash
|
||||
olares-cli upgrade <子命令> [选项]
|
||||
```
|
||||
|
||||
## 子命令
|
||||
|
||||
| 子命令 | 描述 |
|
||||
|--|--|
|
||||
| `precheck` | 对 Olares 执行升级前检查。 |
|
||||
| `spec` | 获取当前 CLI 版本对应的升级规格。 |
|
||||
| `viable` | 判断是否可以基于指定基础版本直接执行升级。 |
|
||||
|
||||
## 全局选项
|
||||
|
||||
以下选项适用于`upgrade`主命令,需要时可被子命令继承。
|
||||
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--base-dir` | `-b` | 设置 Olares 安装包的基本目录。 | 否 | `$HOME/.olares` |
|
||||
| `--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--version` | `-v` | 设置要升级到的目标 Olares 版本,例如`1.10.0`、`1.10.0-20241109`。 | 否 | 无 |
|
||||
|
||||
## `viable` 专属选项
|
||||
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--base` | `-b` | 要检查的基础版本。 | 否 | 当前 Olares 系统版本 |
|
||||
|
||||
:::warning 选项冲突
|
||||
主命令使用`-b`作为`--base-dir`的简写。但在执行`upgrade viable`时,`-b`指代的是`--base`。
|
||||
:::
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 检查当前系统是否可以直接升级
|
||||
sudo olares-cli upgrade viable
|
||||
|
||||
# 检查从指定基础版本开始是否可直接升级
|
||||
sudo olares-cli upgrade viable --base 1.9.0
|
||||
|
||||
# 执行升级前检查
|
||||
sudo olares-cli upgrade precheck
|
||||
|
||||
# 查看当前 CLI 对应的升级规格
|
||||
sudo olares-cli upgrade spec
|
||||
```
|
||||
@@ -1,8 +1,8 @@
|
||||
# `user activate`
|
||||
# `activate`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`user activate`命令用于激活已有的 Olares 账户,你需要至少提供 Olares ID、登录密码和助记词短语才能完成激活。该命令通常需要使用管理员权限(`sudo`)执行。
|
||||
`activate`子命令用于激活已有的 Olares 账户,你需要至少提供 Olares ID、登录密码和助记词短语才能完成激活。
|
||||
|
||||
```bash
|
||||
olares-cli user activate <Olares ID> [选项]
|
||||
@@ -11,7 +11,7 @@ olares-cli user activate <Olares ID> [选项]
|
||||
|
||||
| 参数 | 描述 | 是否必需 |
|
||||
|--|--|--|
|
||||
| `<Olares ID>` | 指定待激活的 Olares 用户账户的唯一标识符。<br>格式类似电子邮件地址(例如:`alice123@olares.com`)| **是** |
|
||||
| `<Olares ID>` | 指定待激活的 Olares 用户账户的唯一标识符。<br>格式类似电子邮件地址。例如:`alice123@olares.com`| 是 |
|
||||
|
||||
## 选项
|
||||
|
||||
@@ -24,19 +24,20 @@ olares-cli user activate <Olares ID> [选项]
|
||||
| `--jws` | | 指定指定 FRP 的 JWS(JSON Web Signature)令牌。<br>仅当`--enable-tunnel`设置为`true`时使用。| 否 | 无 |
|
||||
| `--language` | | 设置系统语言。| 否 | `en-US` |
|
||||
| `--location` | | 设置系统时区位置。 | 否 | `Asia/Shanghai` |
|
||||
| `--mnemonic` | | 指定用于激活的 12 词助记词短语。 | **是** | 无 |
|
||||
| `--password` | `-p` | 指定待激活 Olares 账户的登录密码。 | **是** | 无 |
|
||||
| `--mnemonic` | | 指定用于激活的 12 词助记词短语。 | 是 | 无 |
|
||||
| `--password` | `-p` | 指定待激活 Olares 账户的登录密码。 | 是 | 无 |
|
||||
| `--reset-password` | | 指定用于密码重置的新密码。<br>仅在执行密码重置时需要。| 否 | 无 |
|
||||
| `--vault` | | 指定 Vault 服务的 URL。<br>例如:`https://example.com` | 否 | `http://127.0.0.1:30181` |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 激活 Olares 账户
|
||||
sudo olares-cli user activate alice@olares.cn -p "HerPassWord" --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
olares-cli user activate alice123@olares.cn -p "HerPassWord" --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
|
||||
# 启用隧道模式激活 Olares 账户
|
||||
sudo olares-cli user activate david@olares.cn -p "HisPassWord" --enable-tunnel --host "frp-gateway.olares.com" --jws "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.demo.signature" --bfl http://127.0.0.1:30180 --vault http://127.0.0.1:30180/server --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
olares-cli user activate david456@olares.cn -p "HisPassWord" --enable-tunnel --host "frp-gateway.olares.com" --jws "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.demo.signature" --bfl http://127.0.0.1:30180 --vault http://127.0.0.1:30180/server --mnemonic "apple banana cherry door eagle forest grape house island jacket kite lemon"
|
||||
|
||||
# 使用指定的语言和时区设置,激活 Olares 账户
|
||||
sudo olares-cli user activate carol@olares.cn -p "AnotherPassWord" --mnemonic "alpha beta gamma delta epsilon zeta eta theta iota kappa lambda mu" --language "cn-ZH" --location "Asia/Shanghai"
|
||||
olares-cli user activate carol789@olares.cn -p "AnotherPassWord" --mnemonic "alpha beta gamma delta epsilon zeta eta theta iota kappa lambda mu" --language "cn-ZH" --location "Asia/Shanghai"
|
||||
```
|
||||
46
docs/zh/developer/install/cli/user-create.md
Normal file
@@ -0,0 +1,46 @@
|
||||
# `create`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`create`子命令用于在 Olares 中创建一个新的用户。管理员可以在创建时设置用户名、初始密码、角色权限以及资源限制等初始配置。
|
||||
|
||||
**别名**:`create`、`add`、`new`
|
||||
|
||||
```bash
|
||||
olares-cli user create <用户名> [选项]
|
||||
```
|
||||
|
||||
## 参数
|
||||
|
||||
| 参数 | 说明 | 是否必需|
|
||||
|--|--|--|
|
||||
| `<用户名>` | 指定新用户的用户名。通常为 Olares ID 中`@`符号之前的部分。<br>例如`alice123@olares.com`中的`alice123`。| 是 |
|
||||
|
||||
## 选项
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--cpu-limit` | `-c` | 设置用户环境的 CPU 限制。 | 否 | `1` |
|
||||
| `--description` | | 为用户账号添加描述信息。 | 否 | 无 |
|
||||
| `--display-name` | | 设置用户的显示名称。 | 否 | 无 |
|
||||
| `--domain` | | 指定 Olares ID 使用的域名。 | 否 | 系统默认域名 |
|
||||
| `--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--kubeconfig` | | 指定 kubeconfig 文件路径。 | 否 | 无 |
|
||||
| `--memory-limit` | `-m` | 设置用户环境的内存限制。 | 否 | `3G` |
|
||||
| `--password` | `-p` | 设置用户的初始登录密码。 | 否 | 无 |
|
||||
| `--role` | `-r` | 设置用户角色。<br>可选值:`owner`、`admin`、`normal`。 | 否 | `normal` |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 使用默认设置创建用户
|
||||
olares-cli user create alice123
|
||||
|
||||
# 创建用户并指定密码和角色
|
||||
olares-cli user create blake123 -p "StrongPassword123" -r admin
|
||||
|
||||
# 创建用户并设置资源限制(2 个 CPU 核心,4 GB 内存)
|
||||
olares-cli user create carol123 --cpu-limit 2 --memory-limit 4G
|
||||
|
||||
# 创建用户并设置显示名称和描述
|
||||
olares-cli user create david123 --display-name "David Smith" --description "Data platform administrator"
|
||||
```
|
||||
30
docs/zh/developer/install/cli/user-delete.md
Normal file
@@ -0,0 +1,30 @@
|
||||
# `delete`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`delete`子命令用于从 Olares 系统中永久删除一个已有的用户账号。
|
||||
|
||||
**别名**:`delete`、`d`、`del`、`rm`、`remove`
|
||||
|
||||
```bash
|
||||
olares-cli user delete <用户名> [选项]
|
||||
```
|
||||
|
||||
## 参数
|
||||
|
||||
| 参数 | 说明 | 是否必需|
|
||||
|--|--|--|
|
||||
| `<用户名>` | 指定要删除的用户名。通常为 Olares ID 中`@`符号之前的部分。<br>例如 `alice123@olares.com`中的`alice123`。| 是 |
|
||||
|
||||
## 选项
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--kubeconfig` | | 指定 kubeconfig 文件路径。 | 否 | 无 |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 删除名为 alice123 的用户
|
||||
olares-cli user delete alice123
|
||||
```
|
||||
33
docs/zh/developer/install/cli/user-get.md
Normal file
@@ -0,0 +1,33 @@
|
||||
# `get`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`get`子命令用于获取 Olares 指定用户的详细信息。输出结果以表格或 JSON 格式显示。
|
||||
|
||||
```bash
|
||||
olares-cli user get <用户名> [选项]
|
||||
```
|
||||
|
||||
## 参数
|
||||
|
||||
| 参数 | 说明 | 是否必需|
|
||||
|--|--|--|
|
||||
| `<用户名>` | 指定要查询的用户名。通常为 Olares ID 中`@`符号之前的部分。<br>例如 `alice123@olares.com`中的`alice123`。| 是 |
|
||||
|
||||
## 选项
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--kubeconfig` | | 指定 kubeconfig 文件路径。 | 否 | 无 |
|
||||
| `--no-headers` | | 输出结果不显示表头。 | 否 | 无 |
|
||||
| `--output` | `-o` | 指定输出格式。<br>可选值:`table`、`json`。 | 否 | `table` |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 以默认表格格式查看用户 alice123 的信息
|
||||
olares-cli user get alice123
|
||||
|
||||
# 以 JSON 格式查看用户 blake123 的信息
|
||||
olares-cli user get blake123 -o json
|
||||
```
|
||||
34
docs/zh/developer/install/cli/user-list.md
Normal file
@@ -0,0 +1,34 @@
|
||||
# `list`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`list`子命令用于显示 Olares 系统中所有注册用户列表。你可以根据需要筛选用户并排序,以表格或 JSON 格式显示结果。
|
||||
|
||||
**别名**:`list`、`ls`、`l`
|
||||
|
||||
```bash
|
||||
olares-cli user list [选项]
|
||||
```
|
||||
|
||||
## 选项
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
| `--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--kubeconfig` | | 指定 kubeconfig 文件路径。 | 否 | 无 |
|
||||
| `--no-headers` | | 输出结果不显示表头。 | 否 | 无 |
|
||||
| `--output` | `-o`| 指定输出格式。<br>可选值:`table`、`json`。| 否 | `table` |
|
||||
| `--reverse` | `-r` | 倒序排列输出结果。 | 否 | 无 |
|
||||
| `--sort` | | 按指定字段对结果进行排序。<br>可选值:`name`、`role`、`create-time`、`memory`、`cpu`。 | 否 | 无 |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 以表格格式列出所有用户
|
||||
olares-cli user list
|
||||
|
||||
# 以 JSON 格式列出所有用户
|
||||
olares-cli user list -o json
|
||||
|
||||
# 按角色排序列出用户
|
||||
olares-cli user list --sort role
|
||||
```
|
||||
29
docs/zh/developer/install/cli/user-reset-password.md
Normal file
@@ -0,0 +1,29 @@
|
||||
# `reset-password`
|
||||
|
||||
## 命令说明
|
||||
|
||||
`reset-password`子命令用于通过认证服务强制重置指定用户的登录密码。
|
||||
|
||||
```bash
|
||||
olares-cli user reset-password <用户名> [选项]
|
||||
```
|
||||
|
||||
## 参数
|
||||
|
||||
| 参数 | 说明 | 是否必需 |
|
||||
|--|--|--|
|
||||
| `<用户名>` | 指定要重置密码的用户名。通常为 Olares ID 中`@`符号之前的<br>部分。例如`alice123@olares.com`中的`alice123`。| 是 |
|
||||
|
||||
## 选项
|
||||
| 选项 | 简写 | 用途 | 是否必需 | 默认值 |
|
||||
|--|--|--|--|--|
|
||||
`--help` | `-h` | 显示帮助信息。 | 否 | 无 |
|
||||
| `--kubeconfig` | | 指定 kubeconfig 文件路径。 | 否 | 无 |
|
||||
| `--password` | `-p` | 指定为该用户设置的新密码。 | 是 | 无 |
|
||||
|
||||
## 使用示例
|
||||
|
||||
```bash
|
||||
# 重置用户 alice123 的密码
|
||||
olares-cli user reset-password alice123 -p "NewSecurePassword456!"
|
||||
```
|
||||
13
docs/zh/developer/install/cli/user.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# `user`
|
||||
`user`命令提供了一组用户管理工具,可用于创建、激活、查询和删除 Olares 用户,并支持通过已配置的认证提供方重置用户密码。
|
||||
|
||||
## 子命令
|
||||
|
||||
| 子命令 | 描述 |
|
||||
|--|--|
|
||||
| `activate` | 激活已有的 Olares 账户。 |
|
||||
| `create` | 创建新用户。 |
|
||||
| `delete` | 删除已有用户。 |
|
||||
| `get` | 获取指定用户的详细信息。 |
|
||||
| `list` | 列出 Olares 中的所有用户。 |
|
||||
| `reset-password` | 通过认证提供方强制重置指定用户的密码。|
|
||||
@@ -29,7 +29,7 @@ spec:
|
||||
name: check-auth
|
||||
containers:
|
||||
- name: auth-front
|
||||
image: beclab/login:v1.6.38
|
||||
image: beclab/login:v1.7.4
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 80
|
||||
|
||||
@@ -210,7 +210,7 @@ spec:
|
||||
command:
|
||||
- /samba_share
|
||||
- name: files
|
||||
image: beclab/files-server:v0.2.146
|
||||
image: beclab/files-server:v0.2.148
|
||||
imagePullPolicy: IfNotPresent
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: true
|
||||
@@ -314,8 +314,8 @@ spec:
|
||||
value: os.users
|
||||
- name: NATS_SUBJECT_SYSTEM_GROUPS
|
||||
value: os.groups
|
||||
- name: RESERVED_SPACE
|
||||
value: '1000'
|
||||
- name: RESERVED_SPACE_PERCENT
|
||||
value: '1.00'
|
||||
- name: OLARES_VERSION
|
||||
value: '1.12'
|
||||
- name: FILE_CACHE_DIR
|
||||
|
||||
@@ -240,7 +240,7 @@ spec:
|
||||
value: os_framework_search3
|
||||
containers:
|
||||
- name: search3
|
||||
image: beclab/search3:v0.1.2
|
||||
image: beclab/search3:v0.1.3
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
@@ -301,7 +301,7 @@ spec:
|
||||
priorityClassName: "system-cluster-critical"
|
||||
containers:
|
||||
- name: search3monitor
|
||||
image: beclab/search3monitor:v0.1.2
|
||||
image: beclab/search3monitor:v0.1.3
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 8081
|
||||
|
||||
@@ -64,7 +64,7 @@ spec:
|
||||
operator: Exists
|
||||
containers:
|
||||
- name: search3-validation
|
||||
image: beclab/search3validation:v0.1.2
|
||||
image: beclab/search3validation:v0.1.3
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 8443
|
||||
|
||||
@@ -4,7 +4,7 @@ nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
namespaceOverride: ""
|
||||
imagePullSecrets: []
|
||||
version: "v2.6.7"
|
||||
version: "v2.6.8"
|
||||
|
||||
# Nvidia GPU Parameters
|
||||
resourceName: "nvidia.com/gpu"
|
||||
|
||||
@@ -3,7 +3,7 @@ target: prebuilt
|
||||
output:
|
||||
containers:
|
||||
-
|
||||
name: beclab/hami:v2.6.7
|
||||
name: beclab/hami:v2.6.8
|
||||
-
|
||||
name: beclab/hami-webui-fe-oss:v1.0.8
|
||||
-
|
||||
|
||||
@@ -5,6 +5,6 @@ output:
|
||||
-
|
||||
name: beclab/apecloud-kubeblocks-tools:1.0.1
|
||||
-
|
||||
name: beclab/apecloud-kubeblocks:1.0.1
|
||||
name: beclab/kubeblocks:1.0.1-ext1
|
||||
-
|
||||
name: beclab/kubeblock-addon-charts:v1.0.1-ext2
|
||||
|
||||
@@ -98,7 +98,7 @@ spec:
|
||||
capabilities:
|
||||
drop:
|
||||
- ALL
|
||||
image: beclab/apecloud-kubeblocks:1.0.1
|
||||
image: beclab/kubeblocks:1.0.1-ext1
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- name: webhook-server
|
||||
|
||||