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

update to allow s3 in codfw1dev #368

Merged
merged 1 commit into from
Jan 26, 2024
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
Binary file modified ansible/files/csi-secret-cinderplugin.yaml.codfw1dev.crypt
Binary file not shown.
4 changes: 2 additions & 2 deletions deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ pip install ansible==8.1.0 kubernetes==26.1.0


cd tofu
AWS_ACCESS_KEY_ID=${ACCESS_KEY} AWS_SECRET_ACCESS_KEY=${SECRET_KEY} tofu init
AWS_ACCESS_KEY_ID=${ACCESS_KEY} AWS_SECRET_ACCESS_KEY=${SECRET_KEY} tofu apply -var datacenter=${datacenter} # -auto-approve
AWS_ACCESS_KEY_ID=${ACCESS_KEY} AWS_SECRET_ACCESS_KEY=${SECRET_KEY} tofu init -backend-config=${datacenter}-backend.conf
AWS_ACCESS_KEY_ID=${ACCESS_KEY} AWS_SECRET_ACCESS_KEY=${SECRET_KEY} tofu apply -var datacenter=${datacenter}
export KUBECONFIG=$(pwd)/kube.config

if [ "${tofuonly}" = '1' ]
Expand Down
14 changes: 7 additions & 7 deletions paws/codfw.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,27 @@ jupyterhub:
extraVolumes:
- name: homes
nfs:
server: haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud
server: pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud
path: /srv/paws/project
- name: dumps
nfs:
server: haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud
server: pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud
path: /
# Without this, dumps becomes inaccessible and can hang the host
- name: dumps-src1
nfs:
server: haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud
server: pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud
path: /
- name: dumps-src2
nfs:
server: haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud
server: pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud
path: /
extraConfig:
00-myConfig: |
localdev = False
nfs_home = 'haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud'
dumps_src1 = 'haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud'
dumps_src2 = 'haproxy-and-nfs.paws-dev.codfw1dev.wikimedia.cloud'
nfs_home = 'pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud'
dumps_src1 = 'pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud'
dumps_src2 = 'pawsdev-nfs.pawsdev.codfw1dev.wikimedia.cloud'
ingress:
enabled: true
hosts:
Expand Down
Binary file added secrets-codfw1dev.sh
Binary file not shown.
Binary file modified secrets-eqiad1.sh
Binary file not shown.
11 changes: 11 additions & 0 deletions tofu/codfw1dev-backend.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# https://github.com/hashicorp/terraform/issues/13022

region = "codfw1dev"
bucket = "pawsdev:tofu-state"
endpoint = "https://object.codfw1dev.wikimediacloud.org"
key = "state/main"


skip_region_validation = true
skip_credentials_validation = true
force_path_style = true
10 changes: 10 additions & 0 deletions tofu/eqiad1-backend.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# https://github.com/hashicorp/terraform/issues/13022

region = "eqiad1"
bucket = "paws:tofu-state"
endpoint = "https://object.eqiad1.wikimediacloud.org"
key = "state/main"

skip_region_validation = true
skip_credentials_validation = true
force_path_style = true
11 changes: 1 addition & 10 deletions tofu/main.tf
Original file line number Diff line number Diff line change
@@ -1,15 +1,6 @@
terraform {
required_version = ">= 1.6.0"
backend "s3" {
region = "eqiad1"
bucket = "paws:tofu-state"
endpoint = "https://object.eqiad1.wikimediacloud.org"
key = "state/main"

skip_region_validation = true
skip_credentials_validation = true
force_path_style = true
}
backend "s3" {}
required_providers {
openstack = {
source = "terraform-provider-openstack/openstack"
Expand Down
Binary file modified tofu/secrets.tf
Binary file not shown.
4 changes: 2 additions & 2 deletions tofu/vars.tf
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ variable "auth-url" {
variable "tenant_id" {
type = map(any)
default = {
"codfw1dev" = "paws-dev"
"codfw1dev" = "pawsdev"
"eqiad1" = "paws"
}
}
variable "application_credential_id" {
type = map(any)
default = {
"codfw1dev" = "e487b78d4c5d4bb6a30c2f7471b03bc0"
"codfw1dev" = "3f7f32ab28484173b127e1fb435057ff"
"eqiad1" = "74fa33352a4a44038e7f924324194fe5"
}
}
Expand Down
Loading