Move various servies to microos
This commit is contained in:
58
core-os-podman/gitea.tf
Normal file
58
core-os-podman/gitea.tf
Normal file
@@ -0,0 +1,58 @@
|
||||
|
||||
data "docker_registry_image" "gitea" {
|
||||
name = "gitea/gitea:latest-rootless"
|
||||
}
|
||||
|
||||
resource "docker_image" "gitea" {
|
||||
name = data.docker_registry_image.gitea.name
|
||||
pull_triggers = [data.docker_registry_image.gitea.sha256_digest]
|
||||
}
|
||||
|
||||
|
||||
resource "docker_container" "gitea" {
|
||||
image = docker_image.gitea.image_id
|
||||
name = "gitea"
|
||||
restart = "always"
|
||||
# user = "1000:1000"
|
||||
|
||||
env = [
|
||||
"GITEA__database__DB_TYPE=mysql",
|
||||
"GITEA__database__HOST=1192.168.3.24:3306",
|
||||
"GITEA__database__NAME=gitea",
|
||||
"GITEA__database__USER=gitea",
|
||||
"GITEA__database__PASSWD=3uM4kBGaNQDo3tsRa9Nh",
|
||||
# "USER_UID=1000",
|
||||
# "USER_GID=1000"
|
||||
]
|
||||
|
||||
mounts {
|
||||
target = "/var/lib/gitea"
|
||||
source = "/var/lib/containers/gitea/data"
|
||||
type = "bind"
|
||||
}
|
||||
|
||||
mounts {
|
||||
target = "/etc/gitea"
|
||||
source = "/var/lib/containers/gitea/config"
|
||||
type = "bind"
|
||||
}
|
||||
|
||||
mounts {
|
||||
target = "/etc/localtime"
|
||||
source = "/etc/localtime"
|
||||
type = "bind"
|
||||
read_only = true
|
||||
}
|
||||
|
||||
lifecycle {
|
||||
ignore_changes = [
|
||||
ulimit,
|
||||
log_opts
|
||||
]
|
||||
}
|
||||
|
||||
networks_advanced {
|
||||
name = docker_network.container-public.name
|
||||
ipv4_address = "192.168.3.25"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user