IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an email to s dot adaszewski at gmail dot com. User accounts are meant only to report issues and/or generate pull requests. This is a purpose-specific Git hosting for ADARED projects. Thank you for your understanding!
Переглянути джерело

More explicit tag/untag for images

tags/0.92
Stanislaw Adaszewski 4 роки тому
джерело
коміт
d2355fab67
2 змінених файлів з 29 додано та 22 видалено
  1. +27
    -20
      focker-compose.yml
  2. +2
    -2
      image.py

+ 27
- 20
focker-compose.yml Переглянути файл

@@ -1,23 +1,30 @@
variables:
ext_if: em0
gateway_ip: 127.0.0.2
#
# focker compose wordpress.yml
# focker compose wordpress.yml backup
# focker compose wordpress.yml restore
#
defaults:
jail:
mount.devfs: true
interface: lo1
exec.start: /bin/sh /etc/rc
exec.stop: /bin/sh /etc/rc.shutdown
pf: |
rdr on $(ext_if) proto tcp from any to any port 80 -> $(jail_ip)
services:
gateway:
image: freebsd-12.1
jail:
ip4.address: $(gateway_ip)
pf:
- pass on $(ext_if)
jails:
wordpress:
image: wordpress-5
mounts:
test-volume2: /mnt/volume2
test-volume: /mnt/volume1
ip4.addr: 127.0.1.1
volumes:
gateway-data: {}
test-volume2: {}
test-volume: {}
commands:
backup:
jail: wordpress
command: |
mysqldump >/mnt/volume2/backup.sql
mounts:
test-volume2: /mnt/volume2
restore:
jail: wordpress
command: |
mysql </mnt/volume2/backup.sql

+ 2
- 2
image.py Переглянути файл

@@ -66,13 +66,13 @@ def command_image_build(args):
def command_image_tag(args):
zfs_untag(args.tags)
zfs_untag(args.tags, focker_type='image')
name, _ = zfs_find(args.reference, focker_type='image', zfs_type='filesystem')
zfs_tag(name, args.tags)
def command_image_untag(args):
zfs_untag(args.tags)
zfs_untag(args.tags, focker_type='image')
def command_image_list(args):


Завантаження…
Відмінити
Зберегти