mirror of
https://github.com/community-scripts/ProxmoxVE
synced 2025-01-10 19:05:09 +00:00
Update Ghost installation script to include URL and modify service execution
This commit is contained in:
parent
0fd64e22a1
commit
4e35e582eb
@ -31,8 +31,9 @@ function update_script() {
|
||||
check_container_resources
|
||||
msg_info "Updating ${APP} LXC"
|
||||
# CHECK FOR NPM HERE !
|
||||
|
||||
if command -v ghost &> /dev/null; then
|
||||
current_version=$(ghost --version | awk '{print $2}')
|
||||
current_version=$(ghost --version | awk '{print $2}') #TO REVIEW
|
||||
latest_version=$(npm show ghost-cli version)
|
||||
if [ "$current_version" != "$latest_version" ]; then
|
||||
msg_info "Updating ${APP} from version $current_version to $latest_version"
|
||||
|
@ -66,7 +66,7 @@ msg_info "Setting up Ghost"
|
||||
mkdir -p /var/www/ghost
|
||||
chown -R ghost-user:ghost-user /var/www/ghost
|
||||
chmod 775 /var/www/ghost
|
||||
sudo -u ghost-user -H sh -c "cd /var/www/ghost && ghost install --db=mysql --dbhost=localhost --dbuser=root --dbpass=ghost --dbname=ghost --no-prompt --no-setup-linux-user --no-setup-nginx --no-setup-ssl --no-setup-systemd"
|
||||
sudo -u ghost-user -H sh -c "cd /var/www/ghost && ghost install --db=mysql --dbhost=localhost --dbuser=root --dbpass=ghost --dbname=ghost --url=http://localhost:2368 --no-prompt --no-setup-linux-user --no-setup-nginx --no-setup-ssl --no-setup-systemd --no-setup-mysql --no-start --no-enable"
|
||||
msg_ok "Ghost setup completed"
|
||||
|
||||
# Creating Service (if needed)
|
||||
@ -77,8 +77,10 @@ Description=${APPLICATION} Service
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/ghost run
|
||||
ExecStart=/usr/bin/ghost start
|
||||
WorkingDirectory=/var/www/ghost
|
||||
User=ghost-user
|
||||
Group=ghost-user
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
|
Loading…
Reference in New Issue
Block a user