Commit 5206e6d1 authored by 神楽坂玲奈's avatar 神楽坂玲奈

scripts

parent 9f996970
...@@ -5,7 +5,16 @@ ...@@ -5,7 +5,16 @@
file: file:
path: /tmp/nextgen path: /tmp/nextgen
state: directory state: directory
- name: postup
copy:
src: scripts/postup.sh
dest: '/etc/wireguard/postup.sh'
mode: u+x
- name: predown
copy:
src: scripts/predown.sh
dest: '/etc/wireguard/predown.sh'
mode: u+x
- name: 'loop through list from a variable' - name: 'loop through list from a variable'
include_tasks: 'protocols/{{item.protocol}}/{{item.protocol}}.yaml' include_tasks: 'protocols/{{item.protocol}}/{{item.protocol}}.yaml'
vars: vars:
......
- name: conf - name: conf
template: template:
src: wg.conf.j2 src: wg.conf.j2
dest: '/tmp/nextgen/{{conn.name}}.conf' dest: '/etc/wireguard/{{conn.name}}.conf'
- name: postup
copy:
src: postup.sh
dest: '/tmp/nextgen/postup.sh'
- name: predown
copy:
src: predown.sh
dest: '/tmp/nextgen/predown.sh'
\ No newline at end of file
- name: placeholder foo - name: placeholder foo
debug: debug:
msg: 'An item: {{params.key}}' msg: 'wgfrp'
#!/usr/bin/env bash #!/usr/bin/env bash
set -e set -e
echo "现在会真正去部署了,请务必带 --limit 运行。"
echo "现在开放测试的节点:south.mycard.moe,yuzurisa.mycard.moe,hk-hkg-alql2.mycard.moe"
read -p '确认无误后按回车继续'
mkdir -p result mkdir -p result
npm run inventory npm run inventory
cd ansible || exit cd ansible || exit
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment