@@ -22,44 +22,21 @@ jobs:
2222 --health-retries 5
2323
2424 steps :
25- - name : Notify Rollbar of deploy start
26- 27- id : rollbar_pre_deploy
28- with :
29- environment : ' production'
30- version : ${{ github.sha }}
31- status : ' started'
32- env :
33- ROLLBAR_ACCESS_TOKEN : ${{ secrets.ROLLBAR_ACCESS_TOKEN }}
34- ROLLBAR_USERNAME : ${{ secrets.ROLLBAR_USERNAME }}
35-
36- - uses : actions/checkout@v2
37-
38- - uses : erlef/setup-beam@v1
25+ - uses : actions/checkout@v3
26+ - name : Setup Elixir
27+ uses : erlef/setup-beam@v1
3928 with :
4029 otp-version : ' 25.2'
4130 elixir-version : ' 1.14.3'
42-
43- - uses : actions/cache@v2
31+ - name : Restore mix build cache
32+ uses : actions/cache@v3
4433 with :
45- path : services/app/deps
46- key : v3-${{ runner.os }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/services/app/mix.lock')) }}
47- restore-keys : |
48- v3-${{ runner.os }}-deps-
49-
50- - uses : actions/cache@v2
51- with :
52- path : services/app/_build
53- key : v3-${{ runner.os }}-build-${{ hashFiles(format('{0}{1}', github.workspace, '/services/app/mix.lock')) }}
54- restore-keys : |
55- v3-${{ runner.os }}-build-
56-
57- - uses : actions/cache@v2
58- with :
59- path : ~/.mix
60- key : v3-${{ runner.os }}-mix-${{ hashFiles(format('{0}{1}', github.workspace, '/services/app/mix.lock')) }}
61- restore-keys : |
62- v3-${{ runner.os }}-mix-
34+ path : |
35+ deps
36+ _build
37+ ~/.mix
38+ key : mix:1-${{ hashFiles('**/mix.lock') }}
39+ restore-keys : mix:1-
6340
6441 - name : Get deps
6542 run : mix deps.get
8764 id : yarn-cache
8865 run : echo "::set-output name=dir::$(yarn cache dir)"
8966
90- - uses : actions/cache@v2
67+ - uses : actions/cache@v3
9168 with :
9269 path : ${{ steps.yarn-cache.outputs.dir }}
9370 key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
@@ -133,21 +110,14 @@ jobs:
133110 - name : Login to Docker Hub
134111 run : echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
135112
136- - run : make docker-build-codebattle
137- - run : make docker-push-codebattle
138- - run : make docker-build-runner
139- - run : make docker-push-runner
140-
141- - name : Notify Rollbar of deploy finish
142- 143- id : rollbar_post_deploy
144- with :
145- environment : ' production'
146- version : ${{ github.sha }}
147- status : ' succeeded'
148- env :
149- ROLLBAR_ACCESS_TOKEN : ${{ secrets.ROLLBAR_ACCESS_TOKEN }}
150- ROLLBAR_USERNAME : ${{ secrets.ROLLBAR_USERNAME }}
113+ - name : Build docker image for codebattle
114+ run : make docker-build-codebattle
115+ - name : Push docker image for codebattle
116+ run : make docker-push-codebattle
117+ - name : Build docker image for runner
118+ run : make docker-build-runner
119+ - name : Push docker image for runner
120+ run : make docker-push-runner
151121
152122 # stop integratoin tests on CI becaues of https://github.com/hexlet-codebattle/codebattle/runs/580337561?check_suite_focus=true
153123 # - name: Pull dockers
0 commit comments