Page MenuHomestyx hydra

No OneTemporary

diff --git a/scripts/install/install_rhel-derivs.sh b/scripts/install/install_rhel-derivs.sh
index b5abfbdd25..78a3375c95 100755
--- a/scripts/install/install_rhel-derivs.sh
+++ b/scripts/install/install_rhel-derivs.sh
@@ -1,138 +1,143 @@
#!/bin/bash
confirm() {
echo "Press RETURN to continue, or ^C to cancel.";
read -e ignored
}
RHEL_VER_FILE="/etc/redhat-release"
+INSTALL_URI=" https://we.phorge.it/book/phorge/article/installation_guide/"
+CONFIG_URI=" https://we.phorge.it/book/phorge/article/configuration_guide/"
+REPOSITORY_URI="https://we.phorge.it/source"
+NAME_MAIN="phorge"
+NAME_ARC="arcanist"
if [[ ! -f $RHEL_VER_FILE ]]
then
echo "It looks like you're not running a Red Hat-derived distribution."
- echo "This script is intended to install Phabricator on RHEL-derived"
+ echo "This script is intended to install $NAME_MAIN on RHEL-derived"
echo "distributions such as RHEL, Fedora, CentOS, and Scientific Linux."
echo "Proceed with caution."
confirm
fi
-echo "PHABRICATOR RED HAT DERIVATIVE INSTALLATION SCRIPT";
-echo "This script will install Phabricator and all of its core dependencies.";
+echo "$NAME_MAIN RED HAT DERIVATIVE INSTALLATION SCRIPT";
+echo "This script will install $NAME_MAIN and all of its core dependencies.";
echo "Run it from the directory you want to install into.";
echo
RHEL_REGEX="release ([0-9]+)\."
if [[ $(cat $RHEL_VER_FILE) =~ $RHEL_REGEX ]]
then
RHEL_MAJOR_VER=${BASH_REMATCH[1]}
else
echo "Ut oh, we were unable to determine your distribution's major"
echo "version number. Please make sure you're running 6.0+ before"
echo "proceeding."
confirm
fi
if [[ $RHEL_MAJOR_VER < 6 && $RHEL_MAJOR_VER > 0 ]]
then
echo "** WARNING **"
echo "A major version less than 6 was detected. Because of this,"
echo "several needed dependencies are not available via default repos."
echo "Specifically, RHEL 5 does not have a PEAR package for php53-*."
echo "We will attempt to install it manually, for APC. Please be careful."
confirm
fi
-echo "Phabricator will be installed to: $(pwd).";
+echo "$NAME_MAIN will be installed to: $(pwd).";
confirm
echo "Testing sudo/root..."
if [[ $EUID -ne 0 ]] # Check if we're root. If we are, continue.
then
sudo true
SUDO="sudo"
if [[ $? -ne 0 ]]
then
echo "ERROR: You must be able to sudo to run this script, or run it as root.";
exit 1
fi
fi
if [[ $RHEL_MAJOR_VER == 5 ]]
then
# RHEL 5's "php" package is actually 5.1. The "php53" package won't let us install php-pecl-apc.
# (it tries to pull in php 5.1 stuff) ...
yum repolist | grep -i epel
if [ $? -ne 0 ]; then
echo "It doesn't look like you have the EPEL repo enabled. We are to add it"
echo "for you, so that we can install git."
$SUDO rpm -Uvh https://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
fi
YUMCOMMAND="$SUDO yum install httpd git php53 php53-cli php53-mysql php53-process php53-devel php53-gd gcc wget make pcre-devel mysql-server"
else
# RHEL 6+ defaults with php 5.3
YUMCOMMAND="$SUDO yum install httpd git php php-cli php-mysql php-process php-devel php-gd php-pecl-apc php-pecl-json php-mbstring mysql-server"
fi
echo "Dropping to yum to install dependencies..."
echo "Running: ${YUMCOMMAND}"
echo "Yum will prompt you with [Y/n] to continue installing."
$YUMCOMMAND
if [[ $? -ne 0 ]]
then
echo "The yum command failed. Please fix the errors and re-run this script."
exit 1
fi
if [[ $RHEL_MAJOR_VER == 5 ]]
then
# Now that we've ensured all the devel packages required for pecl/apc are there, let's
# set up PEAR, and install apc.
echo "Attempting to install PEAR"
wget https://pear.php.net/go-pear.phar
$SUDO php go-pear.phar && $SUDO pecl install apc
fi
if [[ $? -ne 0 ]]
then
echo "The apc install failed. Continuing without APC, performance may be impacted."
fi
pidof httpd 2>&1 > /dev/null
if [[ $? -eq 0 ]]
then
echo "If php was installed above, please run: /etc/init.d/httpd graceful"
else
echo "Please remember to start the httpd with: /etc/init.d/httpd start"
fi
pidof mysqld 2>&1 > /dev/null
if [[ $? -ne 0 ]]
then
echo "Please remember to start the mysql server: /etc/init.d/mysqld start"
fi
confirm
-if [[ ! -e arcanist ]]
+if [[ ! -e "$NAME_ARC" ]]
then
- git clone https://github.com/phacility/arcanist.git
+ git clone "$REPOSITORY_URI/$NAME_ARC.git"
else
- (cd arcanist && git pull --rebase)
+ (cd "$NAME_ARC" && git pull --rebase)
fi
-if [[ ! -e phabricator ]]
+if [[ ! -e "$NAME_MAIN" ]]
then
- git clone https://github.com/phacility/phabricator.git
+ git clone "$REPOSITORY_URI/$NAME_MAIN.git"
else
- (cd phabricator && git pull --rebase)
+ (cd "$NAME_MAIN" && git pull --rebase)
fi
echo
echo
echo "Install probably worked mostly correctly. Continue with the 'Configuration Guide':";
echo
-echo " https://secure.phabricator.com/book/phabricator/article/configuration_guide/";
+echo $CONFIG_URI
diff --git a/scripts/install/install_ubuntu.sh b/scripts/install/install_ubuntu.sh
index 7f5f552fdf..2694a4ab9b 100755
--- a/scripts/install/install_ubuntu.sh
+++ b/scripts/install/install_ubuntu.sh
@@ -1,117 +1,123 @@
#!/bin/bash
confirm() {
echo "Press RETURN to continue, or ^C to cancel.";
read -e ignored
}
-INSTALL_URI=" https://phurl.io/u/install"
+INSTALL_URI=" https://we.phorge.it/book/phorge/article/installation_guide/"
+CONFIG_URI=" https://we.phorge.it/book/phorge/article/configuration_guide/"
+REPOSITORY_URI="https://we.phorge.it/source"
+NAME_MAIN="phorge"
+NAME_ARC="arcanist"
+
+NAME_UPPER="$(echo $NAME_MAIN | tr a-z A-Z)"
failed() {
echo
echo
echo "Installation has failed."
echo "Text above this message might be useful to understanding what exactly failed."
echo
echo "Please follow this guide to manually complete installation:"
echo
echo $INSTALL_URI
echo
echo "We apologize for the inconvenience."
exit 3
}
ISSUE=`cat /etc/issue`
if [[ $ISSUE != Ubuntu* ]]
then
echo "This script is intended for use on Ubuntu, but this system appears";
echo "to be something else. Your results may vary.";
echo
confirm
fi
-echo "PHABRICATOR UBUNTU INSTALL SCRIPT";
-echo "This script will install Apache, Phabricator and its core dependencies.";
+echo "$NAME_UPPER UBUNTU INSTALL SCRIPT";
+echo "This script will install Apache, $NAME_MAIN and its core dependencies.";
echo "Run it from the directory you want to install into.";
echo
echo "Testing sudo..."
sudo true
if [ $? -ne 0 ]
then
echo "ERROR: You must be able to sudo to run this script.";
exit 1;
fi;
echo 'Testing Ubuntu version...'
VERSION=`lsb_release -rs`
MAJOR=`expr match "$VERSION" '\([0-9]*\)'`
if [ "$MAJOR" -lt 16 ]
then
echo 'This script is intented to install on modern operating systems; Your '
echo 'operating system is too old for this script.'
- echo 'You can still install Phabricator manually - please consult the installation'
- echo 'guide to see how:'
+ echo 'You can still install $NAME_MAIN manually - please consult the'
+ echo 'installation guide to see how:'
echo
echo $INSTALL_URI
echo
exit 2
fi
# Ubuntu 16.04 LTS only has php 7.0 in their repos, so they need this extra ppa.
# Ubuntu 17.4 and up have official 7.2 builds.
if [ "$MAJOR" -eq 16 ]
then
echo 'This version of Ubuntu requires additional resources in order to install'
- echo 'and run Phabricator.'
+ echo 'and run $NAME_MAIN.'
echo 'We will now add a the following package repository to your system:'
echo ' https://launchpad.net/~ondrej/+archive/ubuntu/php'
echo
echo 'This repository is generally considered safe to use.'
confirm
sudo add-apt-repository -y ppa:ondrej/php || failed
fi
ROOT=`pwd`
-echo "Phabricator will be installed to: ${ROOT}.";
+echo "$NAME_MAIN will be installed to: ${ROOT}.";
confirm
echo "Installing dependencies: git, apache, mysql, php...";
echo
sudo apt-get -qq update
sudo apt-get install \
git mysql-server apache2 libapache2-mod-php \
php php-mysql php-gd php-curl php-apcu php-cli php-json php-mbstring \
|| failed
echo "Enabling mod_rewrite in Apache..."
echo
sudo a2enmod rewrite || failed
-echo "Downloading Phabricator and dependencies..."
+echo "Downloading $NAME_MAIN and dependencies..."
echo
-if [ ! -e arcanist ]
+if [ ! -e "$NAME_ARC" ]
then
- git clone https://github.com/phacility/arcanist.git
+ git clone "$REPOSITORY_URI/$NAME_ARC.git"
else
- (cd arcanist && git pull --rebase)
+ (cd "$NAME_ARC" && git pull --rebase)
fi
-if [ ! -e phabricator ]
+if [ ! -e "$NAME_MAIN" ]
then
- git clone https://github.com/phacility/phabricator.git
+ git clone "$REPOSITORY_URI/$NAME_MAIN.git"
else
- (cd phabricator && git pull --rebase)
+ (cd "$NAME_MAIN" && git pull --rebase)
fi
echo
echo
echo "Install probably worked mostly correctly. Continue with the 'Configuration Guide':";
echo
-echo " https://secure.phabricator.com/book/phabricator/article/configuration_guide/";
+echo $CONFIG_URI
echo
echo 'Next step is "Configuring Apache webserver".'
diff --git a/scripts/install/update_phabricator.sh b/scripts/install/update_phorge.sh
similarity index 66%
rename from scripts/install/update_phabricator.sh
rename to scripts/install/update_phorge.sh
index 3831acd963..c84583506b 100755
--- a/scripts/install/update_phabricator.sh
+++ b/scripts/install/update_phorge.sh
@@ -1,53 +1,56 @@
#!/bin/sh
set -e
set -x
-# This is an example script for updating Phabricator, similar to the one used to
-# update <https://secure.phabricator.com/>. It might not work perfectly on your
-# system, but hopefully it should be easy to adapt. This script is not intended
-# to work without modifications.
+# This is an example script for updating Phabricator. It might not work
+# perfectly on your system, but hopefully it should be easy to adapt. This
+# script is not intended to work without modifications.
# NOTE: This script assumes you are running it from a directory which contains
-# arcanist/ and phabricator/.
+# arcanist/ and phorge/. If you named them differently, you can change them
+# here:
+NAME_MAIN="phorge"
+NAME_ARC="arcanist"
+
ROOT=`pwd` # You can hard-code the path here instead.
### UPDATE WORKING COPIES ######################################################
-cd $ROOT/arcanist
+cd $ROOT/$NAME_ARC
git pull
-cd $ROOT/phabricator
+cd $ROOT/$NAME_MAIN
git pull
### CYCLE WEB SERVER AND DAEMONS ###############################################
# Stop daemons.
-$ROOT/phabricator/bin/phd stop
+$ROOT/$NAME_MAIN/bin/phd stop
# If running the notification server, stop it.
-# $ROOT/phabricator/bin/aphlict stop
+# $ROOT/$NAME_MAIN/bin/aphlict stop
# Stop the webserver (apache, nginx, lighttpd, etc). This command will differ
# depending on which system and webserver you are running: replace it with an
# appropriate command for your system.
# NOTE: If you're running php-fpm, you should stop it here too.
sudo /etc/init.d/httpd stop
# Upgrade the database schema. You may want to add the "--force" flag to allow
# this script to run noninteractively.
-$ROOT/phabricator/bin/storage upgrade
+$ROOT/$NAME_MAIN/bin/storage upgrade
# Restart the webserver. As above, this depends on your system and webserver.
# NOTE: If you're running php-fpm, restart it here too.
sudo /etc/init.d/httpd start
# Restart daemons.
-$ROOT/phabricator/bin/phd start
+$ROOT/$NAME_MAIN/bin/phd start
# If running the notification server, start it.
-# $ROOT/phabricator/bin/aphlict start
+# $ROOT/$NAME_MAIN/bin/aphlict start

File Metadata

Mime Type
text/x-diff
Expires
Sat, Sep 20, 8:50 AM (9 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
240595
Default Alt Text
(11 KB)

Event Timeline