Skip to content
Open
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
68 changes: 42 additions & 26 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,45 @@
version: 2
jobs:
terraform-plan:
docker:
- image: hashicorp/terraform:light
steps:
- checkout
- run: terraform init
- run: terraform plan
terraform-apply:
docker:
- image: hashicorp/terraform:light
steps:
- checkout
- run: terraform init
- run: terraform apply -auto-approve
# version: 2
# jobs:
# terraform-plan:
# docker:
# - image: hashicorp/terraform:light
# steps:
# - checkout
# - run: terraform init
# - run: terraform plan
# terraform-apply:
# docker:
# - image: hashicorp/terraform:light
# steps:
# - checkout
# - run: terraform init
# - run: terraform apply -auto-approve
#
# workflows:
# version: 2
# build-deploy:
# jobs:
# - terraform-plan:
# filters:
# branches:
# ignore: master
# - terraform-apply:
# filters:
# branches:
# only: master

# Use the latest 2.1 version of CircleCI pipeline processing engine, see https://circleci.com/docs/2.0/configuration-reference/
version: 2.1

# Use a package of configuration called an orb, see https://circleci.com/docs/2.0/orb-intro/
orbs:
# Declare a dependency on the welcome-orb
welcome: circleci/welcome-orb@0.3.1

# Orchestrate or schedule a set of jobs, see https://circleci.com/docs/2.0/workflows/
workflows:
version: 2
build-deploy:
# Name the workflow "Welcome"
Welcome:
# Run the welcome/run job in its own container
jobs:
- terraform-plan:
filters:
branches:
ignore: master
- terraform-apply:
filters:
branches:
only: master
- welcome/run
10 changes: 5 additions & 5 deletions people.tf
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
resource "github_membership" "yuukigoodman" {
username = "yuukigoodman"
role = "admin"
}

resource "github_membership" "runamoon" {
username = "runamoon"
role = "member"
Expand All @@ -7,8 +12,3 @@ resource "github_membership" "ryu39" {
username = "ryu39"
role = "member"
}

resource "github_membership" "yuukigoodman" {
username = "yuukigoodman"
role = "member"
}
23 changes: 20 additions & 3 deletions teams.tf
Original file line number Diff line number Diff line change
@@ -1,10 +1,27 @@
resource "github_team" "members" {
name = "members"
privacy = "closed"
name = "members"
privacy = "closed"
}

resource "github_team_membership" "member" {
resource "github_team_membership" "members_ojiry" {
team_id = "${github_team.members.id}"
username = "ojiry"
role = "maintainer"
}

resource "github_team" "techbookfest" {
name = "techbookfest"
privacy = "closed"
}

resource "github_team_membership" "techbookfest_ojiry" {
team_id = "${github_team.techbookfest.id}"
username = "ojiry"
role = "maintainer"
}

resource "github_team_membership" "techbookfest_yuukigoodman" {
team_id = "${github_team.techbookfest.id}"
username = "yuukigoodman"
role = "maintainer"
}
14 changes: 14 additions & 0 deletions techbookfest.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
resource "github_repository" "techbookfest" {
name = "techbookfest"
description = ""
private = true
has_issues = true
has_wiki = true
has_downloads = true
}

resource "github_team_repository" "techbookfest" {
team_id = "${github_team.techbookfest.id}"
repository = "${github_repository.techbookfest.name}"
permission = "push"
}