-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
81 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Build | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- master | ||
|
||
env: | ||
LOG_DIR: ${{github.workspace}}/log | ||
BIN_DIR: ${{github.workspace}}/bin | ||
COMPOSE_LOG: ${{github.workspace}}/log/docker-compose.log | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Cache project dependencies | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-clojure-${{ hashFiles('**/project.clj') }} | ||
restore-keys: | | ||
${{ runner.os }}-clojure | ||
- name: Prepare java | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' | ||
java-version: 21 | ||
# ES5 needs this | ||
- run: sudo sysctl -w vm.max_map_count=262144 | ||
# create log & bin dir if missing | ||
- run: mkdir -p $LOG_DIR | ||
- run: mkdir -p $BIN_DIR | ||
- run: docker compose -f containers/dev/docker-compose.yml up -d > $COMPOSE_LOG | ||
# Wait ES 5 | ||
- run: until curl http://127.0.0.1:9205/; do sleep 1; done | ||
- name: Install clojure tools | ||
uses: DeLaGuardo/[email protected] | ||
with: | ||
lein: latest | ||
- run: sudo sh ./script/install-phantom-js-ubuntu.sh | ||
- run: lein do clean, compile :all, test :all, doo phantom test once |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#!/usr/bin/env bash | ||
# This script install PhantomJS in your Debian/Ubuntu System | ||
# | ||
# This script must be run as root: | ||
# sudo sh install_phantomjs.sh | ||
# | ||
# https://gist.github.com/julionc/7476620 | ||
|
||
if [[ $EUID -ne 0 ]]; then | ||
echo "This script must be run as root" 1>&2 | ||
exit 1 | ||
fi | ||
|
||
PHANTOM_VERSION="phantomjs-2.1.1" | ||
ARCH=$(uname -m) | ||
|
||
if ! [ $ARCH = "x86_64" ]; then | ||
$ARCH="i686" | ||
fi | ||
|
||
PHANTOM_JS="$PHANTOM_VERSION-linux-$ARCH" | ||
|
||
sudo apt-get update | ||
sudo apt-get install build-essential chrpath libssl-dev libxft-dev -y | ||
sudo apt-get install libfreetype6 libfreetype6-dev -y | ||
sudo apt-get install libfontconfig1 libfontconfig1-dev -y | ||
|
||
cd ~ | ||
wget https://bitbucket.org/ariya/phantomjs/downloads/$PHANTOM_JS.tar.bz2 | ||
sudo tar xvjf $PHANTOM_JS.tar.bz2 | ||
|
||
sudo mv $PHANTOM_JS /usr/local/share | ||
sudo ln -sf /usr/local/share/$PHANTOM_JS/bin/phantomjs /usr/local/bin |