-
Notifications
You must be signed in to change notification settings - Fork 38
Staging Server
These instructions more or less encompass setting up from scratch a server for staging deployments from the unstable buendia apt suite.
Don't set a passphrase on the private key.
ssh-keygen -t ecdsa -b 256 -C "CircleCI deployment" -f buendia-deploy
tar cvf buendia_deploy_keys.tar buendia-deploy*
gpg -c buendia_deploy_keys.tar
git add buendia_deploy_keys.tar.gpg
git commit
rm buendia_deploy_keys.tar
Go to the SSH permissions configuration for this project in CircleCI and add the key there. Then update the deploy-staging job in .circleci/config.yml with the key fingerprint.
First, we set up a droplet in Digital Ocean running Debian 9.7. Add a new SSH key and upload the public key in buendia-staging.
Set the hostname to staging.buendia.org or similar and then set the STAGING_HOST variable in the CircleCI environment setup to same.
Then, log into the staging host as root and run the following:
adduser buendia
echo "buendia ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers.d/10-buendia-user
cp -a .ssh ~buendia
chown -R buendia:buendia ~buendia
apt-get update
apt-get install -y apt-transport-https
# Use buendia-github.list because buendia.list is overwritten by the buendia-* packages
echo "deb [trusted=yes] https://projectbuendia.github.io/builds/packages unstable main java" \
>/etc/apt/sources.list.d/buendia-github.list
apt-get update
apt-get upgrade
apt-get install -y buendia-server buendia-site-test
This host should now be ready for deployment from the deploy-staging CircleCI job.
Back in your own working directory, clean up the unencrypted SSH keys.
rm -f buendia-staging buendia-staging.pub
About the software
System Overview
Client Application
Server Application
Server Platform
Development practices
GitHub Usage
Java Style
Testing
Releases
For field users and testers
Software Install and Configuration
Upon Receiving Your Gear
Setting Up a Tablet
Setting Up a Server
Setting Up an Access Point
Reference Configuration