docker pull cptactionhank/atlassian-confluence:6.10.0
root@harbor:~# mkdir /apps/confluence -pv
正式啓動前拷貝confluence裏面的數據java
# 臨時啓動 (關閉後自動刪除本次啓動的容器) docker run -it --rm --name "confluence-wiki-tmp" \ -u root \ -p "8090:8090" \ -v "/data/confluence:/var/atlassian/confluence" \ -e "CATALINA_OPTS= -Xms256m -Xmx5g" \ cptactionhank/atlassian-confluence:6.10.0
當能夠訪問 http://192.168.60.21:8090 時,繼續執行下面步驟mysql
docker cp confluence-wiki-tmp:/opt/atlassian/confluence /apps
scp root@192.168.60.21:/apps/confluence/confluence/WEB-INF/lib/atlassian-extras-decoder-v2-3.4.1.jar ./atlassian-extras-2.4.jar #或者使用其餘的工具傳輸到window上,而後在重命名
注意:此處破解的文件也能夠保留便於下次使用sql
這個步驟完成後就能夠中斷臨時容器了,臨時容器自動會刪除docker
java -jar confluence_keygen.jar
點擊
patch
、選擇剛剛scp到本地的 atlassian-extras-2.4.jar 包,成功後、本地出現一個新atlassian-extras-2.4.jar
包、舊的jar包被重命名爲atlassian-extras-2.4.bak
bash
scp ./atlassian-extras-2.4.jar root@192.168.60.21:/apps/confluence/confluence/WEB-INF/lib/atlassian-extras-decoder-v2-3.4.1.jar
將新的 jar 包上傳到服務器的目錄,並重命名回原來的名字服務器
- 準備mysql的配置文件
mysql/mysql.cnf
[client] default-character-set = utf8 [mysql] default-character-set = utf8 [mysqld] character_set_server = utf8 collation-server = utf8_bin default-storage-engine = INNODB innodb_log_file_size = 2GB binlog_format = row transaction_isolation = READ-COMMITTED max_allowed_packet = 256M
# cat docker-compose.yml version: '2' services: mysql: image: mysql:5.7 volumes: - "./mysql/:/etc/mysql/conf.d/" - "/data/mysql:/var/lib/mysql" - "/usr/share/zoneinfo/Asia/Shanghai:/etc/localtime" restart: always ports: - "3306:3306" environment: MYSQL_ROOT_PASSWORD: confluence MYSQL_DATABASE: confluence MYSQL_USER: ********** MYSQL_PASSWORD: ********** wiki: image: cptactionhank/atlassian-confluence:6.10.0 volumes: - "/apps/confluence:/opt/atlassian/confluence" - "/data/confluence:/var/atlassian/confluence" - "/usr/share/zoneinfo/Asia/Shanghai:/etc/localtime" restart: always user: root ports: - "8090:8090" environment: - JAVA_OPTS: -Duser.timezone=Asia/Shanghai - CATALINA_OPTS: -Xms256m -Xmx7g depends_on: - mysql
docker-compose up -d
啓動後、訪問http://192.168.60.21:8090 、會自動繼續以前的步驟
app
- 開始安裝
- 從網頁上獲
取服務器ID
,填入破解器。點擊gen
生成key、複製到網頁點擊下一步- 選擇第二項鍊接mysql:
jdbc:mysql://mysql/confluence?useSSL=false
Confluence Home : /var/atlassian/confluence Confluence Installation : /opt/atlassian/confluence
tail -f /data/confluence/logs/atlassian-confluence.log
或掃描關注二維碼,關注更多動態
ide