5.0
ROOT /
pages /
maintenance-mode.md
30 lines | ISO-8859-1 | 1 KB

Maintenance Mode


Some tasks need to be performed in maintenance mode, such as restoring database, resetting administrator password, etc. Below explains how to enter into this mode for different installation flavors:

  • If you are running OneDev as docker container:

    1. Stop the container
    2. Run below command to enter into container:
    docker run -it --rm -v <data dir>:/opt/onedev 1dev/server bash 
    

    Here <data dir> represents the directory storing OneDev data

    1. Change into directory /opt/onedev in the container to perform various maintenance tasks
  • If you are deplolying OneDev into Kubernetes cluster:

    1. Change to directory /path/to/k8s-resources/maintenance, and run command kubectl apply -k .
    2. Run command kubectl get pods -n onedev to check pod name of onedev
    3. Run below command to enter into onedev pod container (replace with the actual pod name obtained in previous step):
    kubectl exec -it -n onedev <onedev-pod-name> bash
    
    1. Change to directory /opt/onedev in the container to perform various maintenance tasks
    2. After performing maintenance tasks, you may start OneDev in normal mode by changing to the production folder and run kubectl apply -k .
  • If you are running OneDev on virtual machine/bare metal machine:

    1. Stop OneDev service
    2. Change to the directory where OneDev is installed to perform maintenance tasks
Please wait...
Page is in error, reload to recover