Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kubernetes 1 #6

Merged
merged 17 commits into from
Nov 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ packer/variables.json
*.retry
**/roles/jdauphantnginx/*
jdauphant.nginx
docker/.env
71 changes: 71 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
image: ruby:2.4.2

stages:
- build
- test
- review
- stage
- production

variables:
DATABASE_URL: 'mongodb://mongo/user_posts'

before_script:
- cd reddit
- bundle install

build_job:
stage: build
script:
- echo 'Building'

test_unit_job:
stage: test
services:
- mongo:latest
script:
- ruby simpletest.rb

test_integration_job:
stage: test
script:
- echo 'Testing 1'

deploy_dev_job:
stage: review
script:
- echo 'Deploy'
environment:
name: dev
url: http://dev.example.com

branch_review:
stage: review
script: echo "Deploy to $CI_ENVIRONMENT_SLUG"
environment:
name: branch/$CI_COMMIT_REF_NAME
url: http://$CI_ENVIRONMENT_SLUG.example.com
only:
- branches
except:
- master

staging:
stage: stage
when: manual
only:
- /^\d+\.\d+\.\d+/
script:
- echo 'Deploy'
environment:
name: stage
url: https://beta.example.com

production:
stage: production
when: manual
script:
- echo 'Deploy'
environment:
name: production
url: http://example.com
Loading
Loading