Clean up CI a bit

This commit is contained in:
Jamil Bou Kheir
2020-04-21 21:27:49 -07:00
parent d049b006f6
commit 536f406cb8
2 changed files with 2 additions and 48 deletions

View File

@@ -1,41 +0,0 @@
#!/usr/bin/env bash
set -xe
# This script scp'd to the build host and executed to create a new release.
orig_dir=`pwd`
# Some preliminary housekeeping
rm -rf /tmp/cloudfire
mkdir -p /tmp/cloudfire
cd /tmp/cloudfire
mv ~/cloudfire_web.tar .
tar -xf cloudfire_web.tar
# Start build
echo 'Building release for system:'
uname -a
# Ensure MIX_ENV is prod throughout the build
export MIX_ENV=prod
# Set terminal to UTF-8
export LC_CTYPE="en_US.UTF-8"
# Set required env vars for the app to boot. These will not be used.
export DATABASE_URL="ecto://dummy:dummy@dummy/dummy"
export SECRET_KEY_BASE="dummy"
# Fetch dependencies, compile, compile static assets
mix local.hex --force
mix local.rebar --force
mix deps.get --only prod
mix compile
cd assets
npm install
cd ..
npm run deploy --prefix ./assets
mix phx.digest
mix release
# XXX: Append version number to release tarball
tar -zcf $HOME/release.tar.gz _build

View File

@@ -32,15 +32,10 @@ jobs:
elixir-version: 1.10.2
otp-version: 22.3.2
- name: Install Dependencies
run: |
cd cloudfire_umbrella/
mix deps.get --only test
run: mix deps.get --only test
- name: Setup Database
run: |
cd cloudfire_umbrella
mix ecto.create
mix ecto.migrate
- name: Run Tests
run: |
cd cloudfire_umbrella/
mix test
run: mix test