-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore(ci): fix preprod * Update review.yml * Update production.yml * Update preproduction.yml * Update preproduction.yml * Update preproduction.yml * Update production.yml
- Loading branch information
Julien Bouquillon
authored
Dec 20, 2021
1 parent
8d0527b
commit a7434ac
Showing
3 changed files
with
75 additions
and
50 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,62 @@ | ||
name: Preproduction | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
concurrency: | ||
cancel-in-progress: true | ||
group: preproduction | ||
|
||
jobs: | ||
############################################################################## | ||
## BUILD AND REGISTER DOCKER IMAGES | ||
############################################################################## | ||
register: | ||
name: Build & Register application | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Get project name | ||
run: | | ||
echo "project=${GITHUB_REPOSITORY#*/}" >> $GITHUB_ENV | ||
- name: Use autodevops build and register | ||
uses: SocialGouv/actions/autodevops-build-register@v1 | ||
with: | ||
environment: "preprod" | ||
project: ${{ env.project }} | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
imageName: monsuivipsy/monsuivipsy-site | ||
|
||
############################################################################## | ||
## GENERATE KUBERNETES MANIFESTS | ||
############################################################################## | ||
manifests: | ||
name: Generate k8s manifests | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Use autodevops manifests generation | ||
uses: SocialGouv/actions/autodevops-manifests@v1 | ||
with: | ||
environment: "preprod" | ||
rancherId: ${{ secrets.RANCHER_PROJECT_ID }} | ||
socialgouvBaseDomain: ${{ secrets.SOCIALGOUV_BASE_DOMAIN }} | ||
|
||
############################################################################## | ||
## DEPLOY APPLICATION OVER KUBERNETES | ||
############################################################################## | ||
deploy: | ||
name: Deploy application | ||
runs-on: ubuntu-latest | ||
needs: [register, manifests] | ||
environment: | ||
name: preproduction | ||
url: https://monsuivipsy-site-preprod.dev.fabrique.social.gouv.fr | ||
steps: | ||
- name: Use autodevops deployment | ||
uses: SocialGouv/actions/autodevops-deploy@v1 | ||
with: | ||
environment: "preprod" | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
kubeconfig: ${{ secrets.KUBECONFIG }} | ||
rancherId: ${{ secrets.RANCHER_PROJECT_ID }} |
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
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 |
---|---|---|
|
@@ -2,8 +2,8 @@ name: Review | |
|
||
on: | ||
push: | ||
branches: | ||
- '**' | ||
branches-ignore: | ||
- master | ||
tags-ignore: | ||
- v* | ||
|
||
|