mirror of
https://github.com/blueprint-community/action-export.git
synced 2026-02-19 04:11:53 +00:00
Compare commits
10 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 52582315eb | |||
| be9389f59b | |||
| 1487bb6b5b | |||
| 769b79a83a | |||
| 891f7437c2 | |||
| 04352cba3f | |||
| 6affb23a92 | |||
| b602a2c22c | |||
| 1e5c8fd21c | |||
|
|
6b57cb2f45 |
11
Dockerfile
11
Dockerfile
@@ -1,11 +1,6 @@
|
||||
FROM ghcr.io/blueprintframework/blueprint:v1.11.10
|
||||
|
||||
ENV BASE_DIR=/srv/pterodactyl
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
COPY ./github/workspace/. /srv/pterodactyl/.blueprint/dev/
|
||||
|
||||
RUN blueprint -build
|
||||
|
||||
RUN identifier=$(cat /srv/pterodactyl/.blueprint/dev/conf.yml | grep -m 1 "identifier:" | cut -d ":" -f2 | xargs) && \
|
||||
cp /srv/pterodactyl/${identifier}.blueprint /github/workspace/${identifier}.blueprint && \
|
||||
echo "${identifier}.blueprint" >> $GITHUB_OUTPUT
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
23
entrypoint.sh
Normal file
23
entrypoint.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
echo "Copying repo files into container"
|
||||
cp -R /github/workspace/. /app/.blueprint/dev/
|
||||
|
||||
echo "Patching export script"
|
||||
sed -i '4d' /app/scripts/commands/developer/export.sh
|
||||
|
||||
cd /app/.blueprint/dev
|
||||
ls
|
||||
|
||||
cd /app/
|
||||
|
||||
echo "Running blueprint export"
|
||||
blueprint -export
|
||||
|
||||
identifier=$(grep -m 1 "identifier:" /app/.blueprint/dev/conf.yml | cut -d ":" -f2 | xargs)
|
||||
|
||||
echo "Copying output back to workspace"
|
||||
cp "/app/${identifier}.blueprint" "/github/workspace/${identifier}.blueprint"
|
||||
|
||||
echo "file=${identifier}.blueprint" >> $GITHUB_OUTPUT
|
||||
Reference in New Issue
Block a user