This page walks you through a complete Artemis installation on Ubuntu 14.04 Trusty Tahr. It covers system requirements, preparing your environment, running the installer, configuring theDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/artemis-development-group/artemis/llms.txt
Use this file to discover all available pages before exploring further.
run.ini symlink, setting up local DNS, and rebuilding the application after code changes.
System requirements
- OS: Ubuntu 14.04 Trusty Tahr (nothing older, nothing newer)
- Architecture: amd64 only (required by pre-built packages and the live-update ID generation)
- RAM: 2 GB minimum (the installer will warn and prompt you to confirm if less is available)
- Privileges: Must be run as root via
sudo; running directly as the root user is not supported — a named non-root user must own the install
Before you begin
Create a non-root user
The installer requires a named non-root user. It reads this from
$SUDO_USER automatically when you run the script with sudo, or you can set it explicitly:Create /home/src
The installer expects the source tree to live under a If you want a different location, set
src directory in the user’s home folder. Create it before running the installer:ARTEMIS_SRC before running the installer.Running the installer
The top-level entry point isinstall-artemis.sh. Run it as superuser from the repository root:
artemis/install/artemis.sh. You can override configuration variables inline:
Sanity checks
Verifies root privileges, confirms the OS is Ubuntu 14.04 on amd64, and checks for at least 2 GB of RAM.
Discover available plugins
Scans
$ARTEMIS_SRC for each directory listed in $ARTEMIS_PLUGINS. Plugins that are not present on disk are skipped with a warning.Install apt packages
Adds the DataStax Cassandra repository, the reddit PPA, and then installs all required system packages via
install_apt.sh. This includes Python libraries, Node.js build tools, nginx, haproxy, gunicorn, and more.Install Cassandra and Zookeeper
Runs
install_cassandra.sh and install_zookeeper.sh to install those services from their respective repositories.Install supporting services
Runs
install_services.sh to install mcrouter, memcached, PostgreSQL, RabbitMQ, haproxy, nginx, gunicorn, and Redis. Waits for memcached (11211), PostgreSQL (5432), and RabbitMQ (5672) to become reachable before continuing.Clone source repositories
Clones
artemis/artemis, artemis/artemis-i18n, artemis/artemis-service-websockets, and artemis/artemis-service-activity into $ARTEMIS_SRC if they are not already present. Upstart configs from each repo’s upstart/ directory are copied to /etc/init/.Configure services
Runs
setup_cassandra.sh, setup_postgres.sh, setup_mcrouter.sh, and setup_rabbitmq.sh to create databases, users, keyspaces, and apply runtime configuration to each service.Install Python packages
Runs
python setup.py develop --no-deps for artemis/r2, i18n, any discovered plugins, websockets, and activity.Build static files and generate ini
Runs
make clean pyx inside $ARTEMIS_SRC/artemis/r2, creates development.update with your domain and plugin list (if not already present), and generates development.ini by running make ini.Create run.ini symlink
Creates a
run.ini symlink pointing at development.ini (if no symlink exists yet). See post-install configuration to switch this to production.ini.Install helper scripts and configure nginx/haproxy
Installs
artemis-run, artemis-shell, artemis-start, artemis-stop, artemis-restart, artemis-flush, and artemis-serve into /usr/local/bin/. Writes nginx and haproxy configurations and restarts both services.Start Upstart services
Emits
artemis-stop and then artemis-start via initctl to bring up all registered Upstart jobs, including the websocket and activity services.Post-install configuration
Configuring run.ini
The application reads its runtime configuration from$ARTEMIS_SRC/artemis/r2/run.ini, which is a symlink. The installer creates it pointing at development.ini. For a production deployment, update the symlink to point at production.ini:
- Development
- Production
development.ini enables the Pylons debug stacktrace page and disables ads, captchas, rate limiting, and admin OTP. Do not use this on a publicly accessible server — the stacktrace allows remote code execution.Setting up the hosts file
Artemis defaults to the domainartemis.local. Add an entry to your host machine’s /etc/hosts file (or the hosts file of the machine you browse from) to resolve this name to the server’s IP:
http://artemis.local in your browser.
The domain you use must contain at least one dot (
.). Browsers refuse to set cookies for dotless hostnames. If you do not have a proper domain, an IP address works — for example, setting ARTEMIS_DOMAIN=192.168.1.100 is valid.Rebuilding after code changes
Static files in$ARTEMIS_SRC/artemis/r2/r2/public/static take effect immediately without a rebuild. For all other changes, you need to rebuild and restart:
artemis-restart emits the artemis-restart Upstart event, which triggers a restart of all registered Artemis services. You can restart a single named service by passing its name:
Security disclaimer
Artemis does not make any claims about the security or reliability of this software and is not liable if you are compromised. Portions of this code and assets are © 2005–2015 reddit Inc. If you discover a vulnerability, contactartemis@cocaine.ninja for assistance or ethical disclosure.