Skip to content
This repository has been archived by the owner on Oct 22, 2019. It is now read-only.

Commit

Permalink
Initial Azure Pipelines support
Browse files Browse the repository at this point in the history
  • Loading branch information
StuartWheater committed Oct 19, 2018
1 parent 29c5144 commit 305641f
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 0 deletions.
3 changes: 3 additions & 0 deletions azure-pipelines.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
library(devtools)

check()
54 changes: 54 additions & 0 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
pool:
vmImage: 'Ubuntu 16.04'

steps:
- bash: |
sudo service mysql stop
sudo apt-get update
sudo apt-get remove --purge mysql-client mysql-server mysql-common -y
sudo apt-get purge mysql-client mysql-server mysql-common -y
sudo apt-get autoremove -y
sudo apt-get autoclean -y
sudo rm -rf /var/lib/mysql/
wget -nv https://apt.puppetlabs.com/puppet5-release-xenial.deb
sudo dpkg -i puppet5-release-xenial.deb
sudo apt-get install -qq -f
sudo apt-get update
sudo rm -f puppet5-release-xenial.deb
sudo apt-get install puppet-agent -y
sudo apt-get clean all
sudo apt-get update
sudo apt-get autoremove -y
sudo apt-get clean all
sudo /opt/puppetlabs/puppet/bin/gem install r10k
echo -n "Puppet version: "
/opt/puppetlabs/bin/puppet --version
/opt/puppetlabs/puppet/bin/r10k version
git clone -b ubuntu16 https://github.com/StuartWheater/datashield-infrastructure.git datashield-infrastructure
pushd datashield-infrastructure/puppet/environments/datashield_travis && sudo /opt/puppetlabs/puppet/bin/r10k puppetfile install && popd
sudo /opt/puppetlabs/bin/puppet apply datashield-infrastructure/puppet/environments/datashield_travis/manifests/site.pp --environment datashield_travis --environmentpath datashield-infrastructure/puppet/environments
displayName: 'Install Server'

- bash: |
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
sudo add-apt-repository 'deb [arch=amd64,i386] https://cran.rstudio.com/bin/linux/ubuntu xenial/'
sudo apt-get update
sudo apt-get install -qq libxml2-dev libcurl4-openssl-dev libssl-dev -y
sudo apt-get install -qq r-base -y
sudo R -e "install.packages('devtools', dependencies=TRUE)"
displayName: 'Install R'

- bash: |
R CMD BATCH --quiet azure-pipelines.R azure-pipelines.Rout
displayName: 'Test'

- bash: |
cat azure-pipelines.Rout
grep "0 error" azure-pipelines.Rout
displayName: 'Results'

0 comments on commit 305641f

Please sign in to comment.