This repository was archived by the owner on Sep 26, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +40
-10
lines changed
Expand file tree Collapse file tree 4 files changed +40
-10
lines changed Original file line number Diff line number Diff line change 1- name : Update live developer docs
1+ name : Build developer docs (and deploy on push)
22
33on :
44 push :
55 branches :
66 - master
7+ pull_request :
78
89jobs :
910 build :
1011 runs-on : ubuntu-latest
1112
1213 steps :
13- - name : update live developer docs using SSH
14- uses : garygrossgarten/github-action-ssh@release
14+ - uses : actions/checkout@v2
15+ - uses : ruby/setup-ruby@v1
1516 with :
16- command : cd /var/www/developer && git pull && bundle install --quiet && bundle exec middleman build | grep -E '\b(create|delete|error|update)\b'
17- host : ${{ secrets.SSH_HOST }}
18- username : ${{ secrets.SSH_USER }}
19- passphrase : ${{ secrets.SSH_PASSPHRASE }}
20- privateKey : ${{ secrets.SSH_PRIVATE_KEY }}
17+ ruby-version : 2.3.1
18+ bundler-cache : true
19+ - name : install deps
20+ run : bundle install
21+ - name : build docs
22+ run : bundle exec middleman build
23+ - name : deploy docs
24+ if : ${{ github.event_name == 'push' }}
25+ run : bundle exec middleman deploy
26+ env :
27+ SSH_HOST : ${{ secrets.SSH_HOST }}
28+ SSH_DEPLOYMENT_PATH : ${{ secrets.SSH_PATH }}
29+ SSH_USER : ${{ secrets.SSH_USER }}
30+ SSH_PASSWORD : ${{ secrets.SSH_PASSWORD }}
Original file line number Diff line number Diff line change @@ -12,6 +12,9 @@ gem "middleman-syntax"
1212# Plugin for middleman to generate Github pages
1313gem 'middleman-gh-pages'
1414
15+ # For deploying to Mautic's live server
16+ gem 'middleman-deploy' , '~> 1.0'
17+
1518# Live-reloading plugin
1619gem "middleman-livereload" , "~> 3.3.0"
1720
2730
2831gem "rake" , "~> 12.3.3"
2932
30- gem 'therubyracer' , :platforms => :ruby
33+ gem 'therubyracer' , :platforms => :ruby
Original file line number Diff line number Diff line change 7272 rack-test (~> 0.6.2 )
7373 thor (>= 0.15.2 , < 2.0 )
7474 tilt (~> 1.4.1 , < 2.0 )
75+ middleman-deploy (1.0.0 )
76+ middleman-core (>= 3.2 )
77+ net-sftp
78+ ptools
7579 middleman-gh-pages (0.3.1 )
7680 rake (> 0.9.3 )
7781 middleman-livereload (3.3.4 )
8892 rouge (~> 1.0 )
8993 minitest (5.9.0 )
9094 multi_json (1.15.0 )
95+ net-sftp (3.0.0 )
96+ net-ssh (>= 5.0.0 , < 7.0.0 )
97+ net-ssh (6.1.0 )
9198 padrino-helpers (0.12.8 )
9299 i18n (~> 0.6 , >= 0.6.7 )
93100 padrino-support (= 0.12.8 )
94101 tilt (~> 1.4.1 )
95102 padrino-support (0.12.8 )
96103 activesupport (>= 3.1 )
104+ ptools (1.4.2 )
97105 rack (1.6.13 )
98106 rack-livereload (0.3.16 )
99107 rack
@@ -139,6 +147,7 @@ PLATFORMS
139147
140148DEPENDENCIES
141149 middleman (~> 3.3.0 )
150+ middleman-deploy (~> 1.0 )
142151 middleman-gh-pages
143152 middleman-livereload (~> 3.3.0 )
144153 middleman-syntax
@@ -150,4 +159,4 @@ DEPENDENCIES
150159 wdm (~> 0.1.0 )
151160
152161BUNDLED WITH
153- 1.11.2
162+ 1.17.3
Original file line number Diff line number Diff line change 3535 # set :http_prefix, "/Content/images/"
3636end
3737
38+ activate :deploy do |deploy |
39+ deploy . method = :sftp
40+ deploy . port = 22
41+ deploy . path = ENV [ "SSH_DEPLOYMENT_PATH" ]
42+ deploy . host = ENV [ "SSH_HOST" ]
43+ deploy . user = ENV [ "SSH_USER" ]
44+ deploy . password = ENV [ "SSH_PASSWORD" ]
45+ end
You can’t perform that action at this time.
0 commit comments